<!DOCTYPE html>
<html class="writer-html5" lang="chinese" >
<head>
  <meta charset="utf-8" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
  <title>ualib package &mdash; ualib v1.0.0 documentation</title>
      <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
      <link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
  <!--[if lt IE 9]>
    <script src="_static/js/html5shiv.min.js"></script>
  <![endif]-->
  
        <script data-url_root="./" id="documentation_options" src="_static/documentation_options.js"></script>
        <script src="_static/doctools.js"></script>
        <script src="_static/sphinx_highlight.js"></script>
    <script src="_static/js/theme.js"></script>
    <link rel="index" title="Index" href="genindex.html" />
    <link rel="search" title="Search" href="search.html" /> 
</head>

<body class="wy-body-for-nav"> 
  <div class="wy-grid-for-nav">
    <nav data-toggle="wy-nav-shift" class="wy-nav-side">
      <div class="wy-side-scroll">
        <div class="wy-side-nav-search" >

          
          
          <a href="index.html" class="icon icon-home">
            ualib
          </a>
<div role="search">
  <form id="rtd-search-form" class="wy-form" action="search.html" method="get">
    <input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
    <input type="hidden" name="check_keywords" value="yes" />
    <input type="hidden" name="area" value="default" />
  </form>
</div>
        </div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
              <!-- Local TOC -->
              <div class="local-toc"><ul>
<li><a class="reference internal" href="#">ualib package</a><ul>
<li><a class="reference internal" href="#submodules">Submodules</a></li>
<li><a class="reference internal" href="#module-ualib.core">ualib.core module</a><ul>
<li><a class="reference internal" href="#ualib.core.AdvanceUserArea"><code class="docutils literal notranslate"><span class="pre">AdvanceUserArea</span></code></a><ul>
<li><a class="reference internal" href="#ualib.core.AdvanceUserArea._draw"><code class="docutils literal notranslate"><span class="pre">AdvanceUserArea._draw()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.AdvanceUserArea.convert_colorid_to_vector"><code class="docutils literal notranslate"><span class="pre">AdvanceUserArea.convert_colorid_to_vector()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.AdvanceUserArea.get_scroll_area_value"><code class="docutils literal notranslate"><span class="pre">AdvanceUserArea.get_scroll_area_value()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.AdvanceUserArea.set_min_size"><code class="docutils literal notranslate"><span class="pre">AdvanceUserArea.set_min_size()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.AdvanceUserArea.set_redraw"><code class="docutils literal notranslate"><span class="pre">AdvanceUserArea.set_redraw()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.core.AreaNode"><code class="docutils literal notranslate"><span class="pre">AreaNode</span></code></a><ul>
<li><a class="reference internal" href="#ualib.core.AreaNode._event"><code class="docutils literal notranslate"><span class="pre">AreaNode._event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.AreaNode._mouse_enter_event"><code class="docutils literal notranslate"><span class="pre">AreaNode._mouse_enter_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.AreaNode._mouse_leave_event"><code class="docutils literal notranslate"><span class="pre">AreaNode._mouse_leave_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.AreaNode.extend_shapes"><code class="docutils literal notranslate"><span class="pre">AreaNode.extend_shapes()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.core.BaseBezierItem"><code class="docutils literal notranslate"><span class="pre">BaseBezierItem</span></code></a><ul>
<li><a class="reference internal" href="#ualib.core.BaseBezierItem.LINESTYLE_DASHED"><code class="docutils literal notranslate"><span class="pre">BaseBezierItem.LINESTYLE_DASHED</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseBezierItem.LINESTYLE_DASHED_BIG"><code class="docutils literal notranslate"><span class="pre">BaseBezierItem.LINESTYLE_DASHED_BIG</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseBezierItem.LINESTYLE_DASHED_INV"><code class="docutils literal notranslate"><span class="pre">BaseBezierItem.LINESTYLE_DASHED_INV</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseBezierItem.LINESTYLE_DOTTED"><code class="docutils literal notranslate"><span class="pre">BaseBezierItem.LINESTYLE_DOTTED</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseBezierItem.LINESTYLE_NORMAL"><code class="docutils literal notranslate"><span class="pre">BaseBezierItem.LINESTYLE_NORMAL</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseBezierItem._draw"><code class="docutils literal notranslate"><span class="pre">BaseBezierItem._draw()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseBezierItem._update"><code class="docutils literal notranslate"><span class="pre">BaseBezierItem._update()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseBezierItem.add_bezier_object"><code class="docutils literal notranslate"><span class="pre">BaseBezierItem.add_bezier_object()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseBezierItem.change_object"><code class="docutils literal notranslate"><span class="pre">BaseBezierItem.change_object()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseBezierItem.clean_all_objects"><code class="docutils literal notranslate"><span class="pre">BaseBezierItem.clean_all_objects()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseBezierItem.get_bezier_object"><code class="docutils literal notranslate"><span class="pre">BaseBezierItem.get_bezier_object()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseBezierItem.update_list"><code class="docutils literal notranslate"><span class="pre">BaseBezierItem.update_list()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.core.BaseEvent"><code class="docutils literal notranslate"><span class="pre">BaseEvent</span></code></a><ul>
<li><a class="reference internal" href="#ualib.core.BaseEvent.CHANNEL_MOUSELEFT"><code class="docutils literal notranslate"><span class="pre">BaseEvent.CHANNEL_MOUSELEFT</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.CHANNEL_MOUSEMIDDLE"><code class="docutils literal notranslate"><span class="pre">BaseEvent.CHANNEL_MOUSEMIDDLE</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.CHANNEL_MOUSEMOVE"><code class="docutils literal notranslate"><span class="pre">BaseEvent.CHANNEL_MOUSEMOVE</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.CHANNEL_MOUSERIGHT"><code class="docutils literal notranslate"><span class="pre">BaseEvent.CHANNEL_MOUSERIGHT</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.CHANNEL_MOUSEWHEEL"><code class="docutils literal notranslate"><span class="pre">BaseEvent.CHANNEL_MOUSEWHEEL</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.DEVICE_KEYBOARD"><code class="docutils literal notranslate"><span class="pre">BaseEvent.DEVICE_KEYBOARD</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.DEVICE_MOUSE"><code class="docutils literal notranslate"><span class="pre">BaseEvent.DEVICE_MOUSE</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.EVENT_TYPE_DOWN"><code class="docutils literal notranslate"><span class="pre">BaseEvent.EVENT_TYPE_DOWN</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.EVENT_TYPE_HOLD"><code class="docutils literal notranslate"><span class="pre">BaseEvent.EVENT_TYPE_HOLD</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.EVENT_TYPE_NONE"><code class="docutils literal notranslate"><span class="pre">BaseEvent.EVENT_TYPE_NONE</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.EVENT_TYPE_TIMER"><code class="docutils literal notranslate"><span class="pre">BaseEvent.EVENT_TYPE_TIMER</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.EVENT_TYPE_UP"><code class="docutils literal notranslate"><span class="pre">BaseEvent.EVENT_TYPE_UP</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.QUALIFIERS_ALT"><code class="docutils literal notranslate"><span class="pre">BaseEvent.QUALIFIERS_ALT</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.QUALIFIERS_CTRL"><code class="docutils literal notranslate"><span class="pre">BaseEvent.QUALIFIERS_CTRL</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.QUALIFIERS_NONE"><code class="docutils literal notranslate"><span class="pre">BaseEvent.QUALIFIERS_NONE</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.QUALIFIERS_SHIFT"><code class="docutils literal notranslate"><span class="pre">BaseEvent.QUALIFIERS_SHIFT</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.clone"><code class="docutils literal notranslate"><span class="pre">BaseEvent.clone()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.get_key_value"><code class="docutils literal notranslate"><span class="pre">BaseEvent.get_key_value()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.get_mouse_pos"><code class="docutils literal notranslate"><span class="pre">BaseEvent.get_mouse_pos()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.get_wheel_value"><code class="docutils literal notranslate"><span class="pre">BaseEvent.get_wheel_value()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.init"><code class="docutils literal notranslate"><span class="pre">BaseEvent.init()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.init_event_data"><code class="docutils literal notranslate"><span class="pre">BaseEvent.init_event_data()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_alt_pressed"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_alt_pressed()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_cancel"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_cancel()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_ctrl_pressed"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_ctrl_pressed()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_double_click"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_double_click()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_down_event"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_down_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_handled"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_handled()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_hold_event"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_hold_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_key_pressed"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_key_pressed()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_mouse_left_pressed"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_mouse_left_pressed()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_mouse_middle_pressed"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_mouse_middle_pressed()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_mouse_pressed"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_mouse_pressed()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_mouse_right_pressed"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_mouse_right_pressed()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_mouse_wheel_scrolled"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_mouse_wheel_scrolled()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_redraw"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_redraw()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_shift_pressed"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_shift_pressed()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_special_key_pressed"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_special_key_pressed()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_timer_event"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_timer_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.is_up_event"><code class="docutils literal notranslate"><span class="pre">BaseEvent.is_up_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.set_cancel"><code class="docutils literal notranslate"><span class="pre">BaseEvent.set_cancel()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.set_handled"><code class="docutils literal notranslate"><span class="pre">BaseEvent.set_handled()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseEvent.set_redraw"><code class="docutils literal notranslate"><span class="pre">BaseEvent.set_redraw()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem</span></code></a><ul>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem.BFH_CENTER"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem.BFH_CENTER</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem.BFH_FIT"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem.BFH_FIT</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem.BFH_LEFT"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem.BFH_LEFT</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem.BFH_RIGHT"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem.BFH_RIGHT</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem.BFH_SCALE"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem.BFH_SCALE</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem.BFH_SCALEFIT"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem.BFH_SCALEFIT</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem.BFV_BOTTOM"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem.BFV_BOTTOM</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem.BFV_CENTER"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem.BFV_CENTER</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem.BFV_FIT"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem.BFV_FIT</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem.BFV_SCALE"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem.BFV_SCALE</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem.BFV_SCALEFIT"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem.BFV_SCALEFIT</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem.BFV_TOP"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem.BFV_TOP</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem.DEFUALT_COLOR"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem.DEFUALT_COLOR</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem._mouse_drag_process_event"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem._mouse_drag_process_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem._mouse_drag_start_event"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem._mouse_drag_start_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem._mouse_press_event"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem._mouse_press_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BaseGraphicsItem.set_drag_mouse_follow"><code class="docutils literal notranslate"><span class="pre">BaseGraphicsItem.set_drag_mouse_follow()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.core.BitmapItem"><code class="docutils literal notranslate"><span class="pre">BitmapItem</span></code></a><ul>
<li><a class="reference internal" href="#ualib.core.BitmapItem.FIT_TYPE_FIT"><code class="docutils literal notranslate"><span class="pre">BitmapItem.FIT_TYPE_FIT</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BitmapItem.FIT_TYPE_FULL"><code class="docutils literal notranslate"><span class="pre">BitmapItem.FIT_TYPE_FULL</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BitmapItem.FIT_TYPE_HEIGHT"><code class="docutils literal notranslate"><span class="pre">BitmapItem.FIT_TYPE_HEIGHT</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BitmapItem.FIT_TYPE_NONE"><code class="docutils literal notranslate"><span class="pre">BitmapItem.FIT_TYPE_NONE</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BitmapItem.FIT_TYPE_WIDTH"><code class="docutils literal notranslate"><span class="pre">BitmapItem.FIT_TYPE_WIDTH</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BitmapItem._draw"><code class="docutils literal notranslate"><span class="pre">BitmapItem._draw()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BitmapItem._update"><code class="docutils literal notranslate"><span class="pre">BitmapItem._update()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BitmapItem.change_bmp"><code class="docutils literal notranslate"><span class="pre">BitmapItem.change_bmp()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BitmapItem.change_fit_type"><code class="docutils literal notranslate"><span class="pre">BitmapItem.change_fit_type()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BitmapItem.change_size"><code class="docutils literal notranslate"><span class="pre">BitmapItem.change_size()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.core.BoxContainer"><code class="docutils literal notranslate"><span class="pre">BoxContainer</span></code></a><ul>
<li><a class="reference internal" href="#ualib.core.BoxContainer.LINESTYLE_DASHED"><code class="docutils literal notranslate"><span class="pre">BoxContainer.LINESTYLE_DASHED</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BoxContainer.LINESTYLE_DASHED_BIG"><code class="docutils literal notranslate"><span class="pre">BoxContainer.LINESTYLE_DASHED_BIG</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BoxContainer.LINESTYLE_DASHED_INV"><code class="docutils literal notranslate"><span class="pre">BoxContainer.LINESTYLE_DASHED_INV</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BoxContainer.LINESTYLE_DOTTED"><code class="docutils literal notranslate"><span class="pre">BoxContainer.LINESTYLE_DOTTED</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BoxContainer.LINESTYLE_NORMAL"><code class="docutils literal notranslate"><span class="pre">BoxContainer.LINESTYLE_NORMAL</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BoxContainer._update"><code class="docutils literal notranslate"><span class="pre">BoxContainer._update()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.BoxContainer.add_child"><code class="docutils literal notranslate"><span class="pre">BoxContainer.add_child()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.core.ClipMapTextItem"><code class="docutils literal notranslate"><span class="pre">ClipMapTextItem</span></code></a><ul>
<li><a class="reference internal" href="#ualib.core.ClipMapTextItem._draw"><code class="docutils literal notranslate"><span class="pre">ClipMapTextItem._draw()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.ClipMapTextItem._update"><code class="docutils literal notranslate"><span class="pre">ClipMapTextItem._update()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.ClipMapTextItem.get_text_clipmap_size"><code class="docutils literal notranslate"><span class="pre">ClipMapTextItem.get_text_clipmap_size()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.ClipMapTextItem.set_change"><code class="docutils literal notranslate"><span class="pre">ClipMapTextItem.set_change()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.core.CoreGeUserArea"><code class="docutils literal notranslate"><span class="pre">CoreGeUserArea</span></code></a><ul>
<li><a class="reference internal" href="#ualib.core.CoreGeUserArea.DrawMsg"><code class="docutils literal notranslate"><span class="pre">CoreGeUserArea.DrawMsg()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.CoreGeUserArea.GetMinSize"><code class="docutils literal notranslate"><span class="pre">CoreGeUserArea.GetMinSize()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.CoreGeUserArea.Init"><code class="docutils literal notranslate"><span class="pre">CoreGeUserArea.Init()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.CoreGeUserArea.InitValues"><code class="docutils literal notranslate"><span class="pre">CoreGeUserArea.InitValues()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.CoreGeUserArea.InputEvent"><code class="docutils literal notranslate"><span class="pre">CoreGeUserArea.InputEvent()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.CoreGeUserArea.Message"><code class="docutils literal notranslate"><span class="pre">CoreGeUserArea.Message()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.CoreGeUserArea.Sized"><code class="docutils literal notranslate"><span class="pre">CoreGeUserArea.Sized()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.CoreGeUserArea.Timer"><code class="docutils literal notranslate"><span class="pre">CoreGeUserArea.Timer()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.CoreGeUserArea.new_event"><code class="docutils literal notranslate"><span class="pre">CoreGeUserArea.new_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.CoreGeUserArea.set_clipping_region_with"><code class="docutils literal notranslate"><span class="pre">CoreGeUserArea.set_clipping_region_with()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.CoreGeUserArea.set_mouse_cursor"><code class="docutils literal notranslate"><span class="pre">CoreGeUserArea.set_mouse_cursor()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.core.HBoxContainer"><code class="docutils literal notranslate"><span class="pre">HBoxContainer</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node"><code class="docutils literal notranslate"><span class="pre">Node</span></code></a><ul>
<li><a class="reference internal" href="#ualib.core.Node.DIRTYFLAGS_CHANGES"><code class="docutils literal notranslate"><span class="pre">Node.DIRTYFLAGS_CHANGES</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node.DIRTYFLAGS_MATRIX"><code class="docutils literal notranslate"><span class="pre">Node.DIRTYFLAGS_MATRIX</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node._draw"><code class="docutils literal notranslate"><span class="pre">Node._draw()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node._draw_child"><code class="docutils literal notranslate"><span class="pre">Node._draw_child()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node._draw_event"><code class="docutils literal notranslate"><span class="pre">Node._draw_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node._event"><code class="docutils literal notranslate"><span class="pre">Node._event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node._update"><code class="docutils literal notranslate"><span class="pre">Node._update()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node.change_prop"><code class="docutils literal notranslate"><span class="pre">Node.change_prop()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.core.Node2D"><code class="docutils literal notranslate"><span class="pre">Node2D</span></code></a><ul>
<li><a class="reference internal" href="#ualib.core.Node2D._debug_draw_frame"><code class="docutils literal notranslate"><span class="pre">Node2D._debug_draw_frame()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node2D._doubleclick_event"><code class="docutils literal notranslate"><span class="pre">Node2D._doubleclick_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node2D._key_press_event"><code class="docutils literal notranslate"><span class="pre">Node2D._key_press_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node2D._mouse_drag_process_event"><code class="docutils literal notranslate"><span class="pre">Node2D._mouse_drag_process_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node2D._mouse_drag_release_event"><code class="docutils literal notranslate"><span class="pre">Node2D._mouse_drag_release_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node2D._mouse_drag_start_event"><code class="docutils literal notranslate"><span class="pre">Node2D._mouse_drag_start_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node2D._mouse_move_event"><code class="docutils literal notranslate"><span class="pre">Node2D._mouse_move_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node2D._mouse_press_event"><code class="docutils literal notranslate"><span class="pre">Node2D._mouse_press_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node2D._on_global_frame_changed"><code class="docutils literal notranslate"><span class="pre">Node2D._on_global_frame_changed()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node2D._wheel_event"><code class="docutils literal notranslate"><span class="pre">Node2D._wheel_event()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.Node2D.start_drag_event"><code class="docutils literal notranslate"><span class="pre">Node2D.start_drag_event()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.core.RectItem"><code class="docutils literal notranslate"><span class="pre">RectItem</span></code></a><ul>
<li><a class="reference internal" href="#ualib.core.RectItem.LINESTYLE_DASHED"><code class="docutils literal notranslate"><span class="pre">RectItem.LINESTYLE_DASHED</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.RectItem.LINESTYLE_DASHED_BIG"><code class="docutils literal notranslate"><span class="pre">RectItem.LINESTYLE_DASHED_BIG</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.RectItem.LINESTYLE_DASHED_INV"><code class="docutils literal notranslate"><span class="pre">RectItem.LINESTYLE_DASHED_INV</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.RectItem.LINESTYLE_DOTTED"><code class="docutils literal notranslate"><span class="pre">RectItem.LINESTYLE_DOTTED</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.RectItem.LINESTYLE_NORMAL"><code class="docutils literal notranslate"><span class="pre">RectItem.LINESTYLE_NORMAL</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.RectItem._draw"><code class="docutils literal notranslate"><span class="pre">RectItem._draw()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.core.RoundRectItem"><code class="docutils literal notranslate"><span class="pre">RoundRectItem</span></code></a><ul>
<li><a class="reference internal" href="#ualib.core.RoundRectItem.LINESTYLE_DASHED"><code class="docutils literal notranslate"><span class="pre">RoundRectItem.LINESTYLE_DASHED</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.RoundRectItem.LINESTYLE_DASHED_BIG"><code class="docutils literal notranslate"><span class="pre">RoundRectItem.LINESTYLE_DASHED_BIG</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.RoundRectItem.LINESTYLE_DASHED_INV"><code class="docutils literal notranslate"><span class="pre">RoundRectItem.LINESTYLE_DASHED_INV</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.RoundRectItem.LINESTYLE_DOTTED"><code class="docutils literal notranslate"><span class="pre">RoundRectItem.LINESTYLE_DOTTED</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.RoundRectItem.LINESTYLE_NORMAL"><code class="docutils literal notranslate"><span class="pre">RoundRectItem.LINESTYLE_NORMAL</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.RoundRectItem._update"><code class="docutils literal notranslate"><span class="pre">RoundRectItem._update()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.RoundRectItem.change_size"><code class="docutils literal notranslate"><span class="pre">RoundRectItem.change_size()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.RoundRectItem.get_rect"><code class="docutils literal notranslate"><span class="pre">RoundRectItem.get_rect()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.RoundRectItem.set_radius"><code class="docutils literal notranslate"><span class="pre">RoundRectItem.set_radius()</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.RoundRectItem.set_seperate_radius"><code class="docutils literal notranslate"><span class="pre">RoundRectItem.set_seperate_radius()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.core.SimpelTextItem"><code class="docutils literal notranslate"><span class="pre">SimpelTextItem</span></code></a><ul>
<li><a class="reference internal" href="#ualib.core.SimpelTextItem.COLOR_TRANS"><code class="docutils literal notranslate"><span class="pre">SimpelTextItem.COLOR_TRANS</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.SimpelTextItem.FONT_BIG"><code class="docutils literal notranslate"><span class="pre">SimpelTextItem.FONT_BIG</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.SimpelTextItem.FONT_BIG_BOLD"><code class="docutils literal notranslate"><span class="pre">SimpelTextItem.FONT_BIG_BOLD</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.SimpelTextItem.FONT_BOLD"><code class="docutils literal notranslate"><span class="pre">SimpelTextItem.FONT_BOLD</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.SimpelTextItem.FONT_DEFAULT"><code class="docutils literal notranslate"><span class="pre">SimpelTextItem.FONT_DEFAULT</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.SimpelTextItem.FONT_ITALIC"><code class="docutils literal notranslate"><span class="pre">SimpelTextItem.FONT_ITALIC</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.SimpelTextItem.FONT_MONOSPACED"><code class="docutils literal notranslate"><span class="pre">SimpelTextItem.FONT_MONOSPACED</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.SimpelTextItem.FONT_STANDARD"><code class="docutils literal notranslate"><span class="pre">SimpelTextItem.FONT_STANDARD</span></code></a></li>
<li><a class="reference internal" href="#ualib.core.SimpelTextItem._draw"><code class="docutils literal notranslate"><span class="pre">SimpelTextItem._draw()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.core.VBoxContainer"><code class="docutils literal notranslate"><span class="pre">VBoxContainer</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#module-ualib.utils">ualib.utils module</a><ul>
<li><a class="reference internal" href="#ualib.utils.BaseFrame"><code class="docutils literal notranslate"><span class="pre">BaseFrame</span></code></a><ul>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.ALIGNMENT_CENTER"><code class="docutils literal notranslate"><span class="pre">BaseFrame.ALIGNMENT_CENTER</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.ALIGNMENT_LEFT_BOTTOM"><code class="docutils literal notranslate"><span class="pre">BaseFrame.ALIGNMENT_LEFT_BOTTOM</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.ALIGNMENT_LEFT_MID"><code class="docutils literal notranslate"><span class="pre">BaseFrame.ALIGNMENT_LEFT_MID</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.ALIGNMENT_LEFT_TOP"><code class="docutils literal notranslate"><span class="pre">BaseFrame.ALIGNMENT_LEFT_TOP</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.ALIGNMENT_MID_BOTTOM"><code class="docutils literal notranslate"><span class="pre">BaseFrame.ALIGNMENT_MID_BOTTOM</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.ALIGNMENT_MID_TOP"><code class="docutils literal notranslate"><span class="pre">BaseFrame.ALIGNMENT_MID_TOP</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.ALIGNMENT_RIGHT_BOTTOM"><code class="docutils literal notranslate"><span class="pre">BaseFrame.ALIGNMENT_RIGHT_BOTTOM</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.ALIGNMENT_RIGHT_MID"><code class="docutils literal notranslate"><span class="pre">BaseFrame.ALIGNMENT_RIGHT_MID</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.ALIGNMENT_RIGHT_TOP"><code class="docutils literal notranslate"><span class="pre">BaseFrame.ALIGNMENT_RIGHT_TOP</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.get_box_offset"><code class="docutils literal notranslate"><span class="pre">BaseFrame.get_box_offset()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.get_global_bbox"><code class="docutils literal notranslate"><span class="pre">BaseFrame.get_global_bbox()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.get_global_position"><code class="docutils literal notranslate"><span class="pre">BaseFrame.get_global_position()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.get_overlap_rect_with"><code class="docutils literal notranslate"><span class="pre">BaseFrame.get_overlap_rect_with()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.is_intersect_with"><code class="docutils literal notranslate"><span class="pre">BaseFrame.is_intersect_with()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.is_point_inside"><code class="docutils literal notranslate"><span class="pre">BaseFrame.is_point_inside()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.offset"><code class="docutils literal notranslate"><span class="pre">BaseFrame.offset</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.position"><code class="docutils literal notranslate"><span class="pre">BaseFrame.position</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.rect_overlap"><code class="docutils literal notranslate"><span class="pre">BaseFrame.rect_overlap()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseFrame.size"><code class="docutils literal notranslate"><span class="pre">BaseFrame.size</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy</span></code></a><ul>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.get_children"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.get_children()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.get_down"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.get_down()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.get_downlast"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.get_downlast()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.get_next"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.get_next()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.get_pred"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.get_pred()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.get_up"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.get_up()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.insert_after"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.insert_after()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.insert_before"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.insert_before()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.insert_under"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.insert_under()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.insert_underlast"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.insert_underlast()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.iter_all_children"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.iter_all_children()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.remove"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.remove()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.remove_all_children"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.remove_all_children()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.set_children"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.set_children()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.BaseHierarchy.set_parent"><code class="docutils literal notranslate"><span class="pre">BaseHierarchy.set_parent()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.utils.Signal"><code class="docutils literal notranslate"><span class="pre">Signal</span></code></a><ul>
<li><a class="reference internal" href="#ualib.utils.Signal.connect"><code class="docutils literal notranslate"><span class="pre">Signal.connect()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.Signal.disconnect"><code class="docutils literal notranslate"><span class="pre">Signal.disconnect()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.Signal.emit"><code class="docutils literal notranslate"><span class="pre">Signal.emit()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.utils.SimpleFlag"><code class="docutils literal notranslate"><span class="pre">SimpleFlag</span></code></a><ul>
<li><a class="reference internal" href="#ualib.utils.SimpleFlag.flags"><code class="docutils literal notranslate"><span class="pre">SimpleFlag.flags</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SimpleFlag.flag_names"><code class="docutils literal notranslate"><span class="pre">SimpleFlag.flag_names</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SimpleFlag.clear_all_flags"><code class="docutils literal notranslate"><span class="pre">SimpleFlag.clear_all_flags()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SimpleFlag.clear_flag"><code class="docutils literal notranslate"><span class="pre">SimpleFlag.clear_flag()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SimpleFlag.get_flag_by_position"><code class="docutils literal notranslate"><span class="pre">SimpleFlag.get_flag_by_position()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SimpleFlag.get_flag_names"><code class="docutils literal notranslate"><span class="pre">SimpleFlag.get_flag_names()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SimpleFlag.get_flag_positions"><code class="docutils literal notranslate"><span class="pre">SimpleFlag.get_flag_positions()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SimpleFlag.has_flag"><code class="docutils literal notranslate"><span class="pre">SimpleFlag.has_flag()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SimpleFlag.init_flag"><code class="docutils literal notranslate"><span class="pre">SimpleFlag.init_flag()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SimpleFlag.set_flag"><code class="docutils literal notranslate"><span class="pre">SimpleFlag.set_flag()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SimpleFlag.toggle_flag"><code class="docutils literal notranslate"><span class="pre">SimpleFlag.toggle_flag()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.utils.SingleBezierObject"><code class="docutils literal notranslate"><span class="pre">SingleBezierObject</span></code></a><ul>
<li><a class="reference internal" href="#ualib.utils.SingleBezierObject.attach_bezier"><code class="docutils literal notranslate"><span class="pre">SingleBezierObject.attach_bezier()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SingleBezierObject.change"><code class="docutils literal notranslate"><span class="pre">SingleBezierObject.change()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SingleBezierObject.get_all_points"><code class="docutils literal notranslate"><span class="pre">SingleBezierObject.get_all_points()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SingleBezierObject.get_part"><code class="docutils literal notranslate"><span class="pre">SingleBezierObject.get_part()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SingleBezierObject.get_points"><code class="docutils literal notranslate"><span class="pre">SingleBezierObject.get_points()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.SingleBezierObject.update_list"><code class="docutils literal notranslate"><span class="pre">SingleBezierObject.update_list()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#ualib.utils.get_bitmap_from"><code class="docutils literal notranslate"><span class="pre">get_bitmap_from()</span></code></a></li>
<li><a class="reference internal" href="#ualib.utils.set_mouse_pointer"><code class="docutils literal notranslate"><span class="pre">set_mouse_pointer()</span></code></a></li>
</ul>
</li>
<li><a class="reference internal" href="#module-ualib">Module contents</a></li>
</ul>
</li>
</ul>
</div>
        </div>
      </div>
    </nav>

    <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
          <i data-toggle="wy-nav-top" class="fa fa-bars"></i>
          <a href="index.html">ualib</a>
      </nav>

      <div class="wy-nav-content">
        <div class="rst-content">
          <div role="navigation" aria-label="Page navigation">
  <ul class="wy-breadcrumbs">
      <li><a href="index.html" class="icon icon-home" aria-label="Home"></a></li>
      <li class="breadcrumb-item active">ualib package</li>
      <li class="wy-breadcrumbs-aside">
            <a href="_sources/ualib.rst.txt" rel="nofollow"> View page source</a>
      </li>
  </ul>
  <hr/>
</div>
          <div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
           <div itemprop="articleBody">
             
  <section id="ualib-package">
<h1>ualib package<a class="headerlink" href="#ualib-package" title="Permalink to this heading"></a></h1>
<section id="submodules">
<h2>Submodules<a class="headerlink" href="#submodules" title="Permalink to this heading"></a></h2>
</section>
<section id="module-ualib.core">
<span id="ualib-core-module"></span><h2>ualib.core module<a class="headerlink" href="#module-ualib.core" title="Permalink to this heading"></a></h2>
<p>TODO: UserArea Drag</p>
<div class="line-block">
<div class="line"><strong>Node 对象继承关系:</strong></div>
<div class="line">Node (BaseHierarchy)</div>
<div class="line-block">
<div class="line">| Node2D (BaseFrame)</div>
<div class="line-block">
<div class="line">| AreaNode</div>
<div class="line-block">
<div class="line">| BaseGraphicsItem</div>
<div class="line-block">
<div class="line">| BoxContainer</div>
<div class="line-block">
<div class="line">| HBoxContainer</div>
<div class="line">| VBoxContainer</div>
</div>
<div class="line">| SimpelTextItem</div>
<div class="line">| ClipMapTextItem</div>
<div class="line">| RectItem</div>
<div class="line">| BitmapItem</div>
<div class="line">| BaseBezierItem</div>
<div class="line-block">
<div class="line">| RoundRectItem</div>
</div>
</div>
</div>
</div>
</div>
</div>
<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.AdvanceUserArea">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">AdvanceUserArea</span></span><a class="headerlink" href="#ualib.core.AdvanceUserArea" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.core.Node2D" title="ualib.core.Node2D"><code class="xref py py-class docutils literal notranslate"><span class="pre">Node2D</span></code></a></p>
<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.AdvanceUserArea._draw">
<span class="sig-name descname"><span class="pre">_draw</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">ua</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.AdvanceUserArea._draw" title="Permalink to this definition"></a></dt>
<dd><p>绘制覆写方法，在这里一般只需绘制当前对象本身</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>ua</strong> (<a class="reference internal" href="#ualib.core.CoreGeUserArea" title="ualib.core.CoreGeUserArea"><em>CoreGeUserArea</em></a>) -- core 模块中的 CoreGeUserArea 对象</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.AdvanceUserArea.convert_colorid_to_vector">
<span class="sig-name descname"><span class="pre">convert_colorid_to_vector</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">colorid</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.AdvanceUserArea.convert_colorid_to_vector" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.AdvanceUserArea.get_scroll_area_value">
<span class="sig-name descname"><span class="pre">get_scroll_area_value</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">scroll_group_id</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.AdvanceUserArea.get_scroll_area_value" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.AdvanceUserArea.set_min_size">
<span class="sig-name descname"><span class="pre">set_min_size</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">size</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.AdvanceUserArea.set_min_size" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.AdvanceUserArea.set_redraw">
<span class="sig-name descname"><span class="pre">set_redraw</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">layout_changed</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">False</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.AdvanceUserArea.set_redraw" title="Permalink to this definition"></a></dt>
<dd><p>想要手动重绘制ua时调用该方法</p>
<div class="admonition warning">
<p class="admonition-title">Warning</p>
<p>注意：刷新方法尽量使用该函数，如果是高级开发者，想要直接使用 AUA.ua.Redraw() 或者 AUA.ua.LayoutChanged() 方法的，
请勿在 DrawMsg 函数调用过程中使用，否则会导致C4D陷入死循环而崩溃。比如 Node._update方法默认在 DrawMsg 过程调用。</p>
</div>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>layout_changed</strong> (<em>bool</em><em>, </em><em>optional</em>) -- 界面尺寸发生改变时设置为True, defaults to False</p>
</dd>
</dl>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.AreaNode">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">AreaNode</span></span><a class="headerlink" href="#ualib.core.AreaNode" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.core.Node2D" title="ualib.core.Node2D"><code class="xref py py-class docutils literal notranslate"><span class="pre">Node2D</span></code></a></p>
<p>基础区域对象, 事件只有在区域内部发生才会向下传递, 绘制也可以限制在区域内部</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>mouse_entered</strong> (<a class="reference internal" href="#ualib.utils.Signal" title="ualib.utils.Signal"><em>Signal</em></a>) -- 鼠标进入区域时发送信号</p></li>
<li><p><strong>mouse_leave</strong> (<a class="reference internal" href="#ualib.utils.Signal" title="ualib.utils.Signal"><em>Signal</em></a>) -- 鼠标退出区域时发送信号</p></li>
<li><p><strong>clip_to_frame</strong> (<em>bool</em>) -- &lt;prop&gt; True 裁剪对象绘制范围到自己的 baseframe 范围内, False 关闭裁剪. 细节可以查看 draw_event</p></li>
<li><p><strong>clip_children</strong> -- &lt;prop&gt; True 裁剪子对象绘制范围到当前对象的 baseframe 范围内, False 关闭裁剪. 细节可以查看 draw_event</p></li>
<li><p><strong>clip_optimize</strong> -- &lt;prop&gt; 用于高效渲染, 建议设为True, 会将 baseframe 超出视图区域的对象跳过绘制(draw). 细节可以查看 draw_event</p></li>
</ul>
</dd>
</dl>
<p>其他参数：mouse_inside 鼠标在区域内部时为True</p>
<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.AreaNode._event">
<span class="sig-name descname"><span class="pre">_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.AreaNode._event" title="Permalink to this definition"></a></dt>
<dd><dl class="field-list simple">
</dl>
<p>只有当鼠标在区域内部时向下传递事件</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.AreaNode._mouse_enter_event">
<span class="sig-name descname"><span class="pre">_mouse_enter_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.AreaNode._mouse_enter_event" title="Permalink to this definition"></a></dt>
<dd><dl class="field-list simple">
</dl>
<p>鼠标进入事件在这里执行</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.AreaNode._mouse_leave_event">
<span class="sig-name descname"><span class="pre">_mouse_leave_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.AreaNode._mouse_leave_event" title="Permalink to this definition"></a></dt>
<dd><dl class="field-list simple">
</dl>
<p>鼠标离开事件在这里执行</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.AreaNode.extend_shapes">
<span class="sig-name descname"><span class="pre">extend_shapes</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">shapes</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">[]</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.AreaNode.extend_shapes" title="Permalink to this definition"></a></dt>
<dd><p>扩展当前对象内部判定区域， 在 _check_inside 函数中使用</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>shapes</strong> (<em>list</em><em>, </em><em>optional</em>) -- BaseFrame对象组成的列表. Defaults to [].</p>
</dd>
</dl>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.BaseBezierItem">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">BaseBezierItem</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">position=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">size=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseBezierItem" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.core.BaseGraphicsItem" title="ualib.core.BaseGraphicsItem"><code class="xref py py-class docutils literal notranslate"><span class="pre">BaseGraphicsItem</span></code></a></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseBezierItem.LINESTYLE_DASHED">
<span class="sig-name descname"><span class="pre">LINESTYLE_DASHED</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#ualib.core.BaseBezierItem.LINESTYLE_DASHED" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseBezierItem.LINESTYLE_DASHED_BIG">
<span class="sig-name descname"><span class="pre">LINESTYLE_DASHED_BIG</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">4</span></em><a class="headerlink" href="#ualib.core.BaseBezierItem.LINESTYLE_DASHED_BIG" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseBezierItem.LINESTYLE_DASHED_INV">
<span class="sig-name descname"><span class="pre">LINESTYLE_DASHED_INV</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#ualib.core.BaseBezierItem.LINESTYLE_DASHED_INV" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseBezierItem.LINESTYLE_DOTTED">
<span class="sig-name descname"><span class="pre">LINESTYLE_DOTTED</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#ualib.core.BaseBezierItem.LINESTYLE_DOTTED" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseBezierItem.LINESTYLE_NORMAL">
<span class="sig-name descname"><span class="pre">LINESTYLE_NORMAL</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#ualib.core.BaseBezierItem.LINESTYLE_NORMAL" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseBezierItem._draw">
<span class="sig-name descname"><span class="pre">_draw</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">ua</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseBezierItem._draw" title="Permalink to this definition"></a></dt>
<dd><p>绘制覆写方法，在这里一般只需绘制当前对象本身</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>ua</strong> (<a class="reference internal" href="#ualib.core.CoreGeUserArea" title="ualib.core.CoreGeUserArea"><em>CoreGeUserArea</em></a>) -- core 模块中的 CoreGeUserArea 对象</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseBezierItem._update">
<span class="sig-name descname"><span class="pre">_update</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseBezierItem._update" title="Permalink to this definition"></a></dt>
<dd><p>刷新绘制数据</p>
<dl class="field-list simple">
</dl>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>_update 方法会在 _draw_event 中自动调用，当执行具体的数据刷新时可以利用 dirty flag 来判断刷新时机避免无效的反复刷新（可以极大的提升效率）</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="k">def</span> <span class="nf">_update</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
    <span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">dirty_flag</span><span class="o">.</span><span class="n">has_flag</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">DIRTYFLAGS_CHANGES</span><span class="p">):</span>
        <span class="c1"># 内部数据更新代码写这里</span>
    <span class="k">elif</span> <span class="bp">self</span><span class="o">.</span><span class="n">dirty_flag</span><span class="o">.</span><span class="n">has_flag</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">DIRTYFLAGS_MATRIX</span><span class="p">):</span>
        <span class="c1"># 位置变换数据更新代码写这里</span>
</pre></div>
</div>
</div>
<div class="admonition warning">
<p class="admonition-title">Warning</p>
<p>_update() 本质上是在DrawMsg() 函数中调用的, 所以注意避免直接调用 CoreGeUserArea 的 LayoutChanged() 方法 , 否则可能会因陷入死循环而导致的C4D崩溃</p>
</div>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseBezierItem.add_bezier_object">
<span class="sig-name descname"><span class="pre">add_bezier_object</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">start=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">end=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">start_hand_offset=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">end_hand_offset=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">update=False</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseBezierItem.add_bezier_object" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseBezierItem.change_object">
<span class="sig-name descname"><span class="pre">change_object</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">index</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">part</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">value</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">update</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">True</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseBezierItem.change_object" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseBezierItem.clean_all_objects">
<span class="sig-name descname"><span class="pre">clean_all_objects</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseBezierItem.clean_all_objects" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseBezierItem.get_bezier_object">
<span class="sig-name descname"><span class="pre">get_bezier_object</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">index</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">0</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseBezierItem.get_bezier_object" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseBezierItem.update_list">
<span class="sig-name descname"><span class="pre">update_list</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">innder_update</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">False</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseBezierItem.update_list" title="Permalink to this definition"></a></dt>
<dd><p>将分散的bezier_objects合并为一个对象 并获取全局点位</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>innder_update</strong> -- 完全刷新所有对象的点位 (若已经刷新过,设置为False可以提升效率)</p>
</dd>
</dl>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.BaseEvent">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">BaseEvent</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">CORE</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>基础事件对象，会在每一个事件循环周期由 GeUserArea.InputEvent() 和 GeUserArea.Timer() 创建，并通过 GeUserArea.root._event() 方法传递到节点子级</p>
<div class="admonition note">
<p class="admonition-title">Note</p>
<div class="line-block">
<div class="line">一个事件循环周期是指：</div>
<div class="line-block">
<div class="line">输入事件发生 -&gt; 事件传遍整个节点树 -&gt; 数据刷新 -&gt; 节点绘制</div>
</div>
</div>
</div>
<div class="line-block">
<div class="line">BaseEvent对象主要有以下几种事件：</div>
</div>
<table class="hlist"><tr><td><ul class="simple">
<li><p>is_down_event() -&gt; EVENT_TYPE_DOWN 按下事件 由InputEvent发起</p></li>
<li><p>is_hold_event() -&gt; EVENT_TYPE_HOLD 拖拽事件 由is_down_event发起</p></li>
<li><p>is_up_event() -&gt; EVENT_TYPE_UP   松开事件 由is_down_event发起</p></li>
<li><p>is_timer_event() -&gt; EVENT_TYPE_TIMER 计时器事件 由Timer发起</p></li>
</ul>
</td></tr></table>
<div class="line-block">
<div class="line">可获取的事件数据包括 ：</div>
</div>
<table class="hlist"><tr><td><ul class="simple">
<li><p><strong>mouse_event_position</strong> :列表[x,y] 对应事件按键点击时鼠标的位置</p></li>
<li><p><strong>mouse_down_position</strong> : 列表[x,y] 按键点击时鼠标的位置</p></li>
<li><p><strong>mouse_hold_position</strong> : 列表[x,y] 按键点击并拖动时鼠标的位置</p></li>
<li><p><strong>mouse_up_position</strong> : 列表[x,y] 按键松开时鼠标的位置</p></li>
<li><p><strong>qualifier</strong> : 辅助键位事件 如: ctrl/shift等, 对应 self.QUALIFIERS_CTRL/self.QUALIFIERS_SHIFT ...</p></li>
<li><p><strong>device</strong> :  输入设备: 鼠标 self.DEVICE_MOUSE, 键盘 self.DEVICE_KEYBOARD</p></li>
<li><p><strong>channel</strong> : 输入按键: 鼠标左键中间右键 self.CHANNEL_MOUSELEFT/ self.CHANNEL_MOUSERIGHT/ self.CHANNEL_MOUSEMIDDLE 等等</p></li>
<li><p><strong>value</strong> : 输入按键对应数据, 比如滚轮事件的数据</p></li>
<li><p><strong>doubleclick</strong> : 是否是双击</p></li>
</ul>
</td></tr></table>
<div class="admonition note">
<p class="admonition-title">Note</p>
<div class="line-block">
<div class="line">基础的事件数据（_event_data）可以通过 __getitem__ 方法获取</div>
</div>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="k">def</span> <span class="nf">_event</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">event</span><span class="p">:</span> <span class="n">BaseEvent</span><span class="p">):</span>
    <span class="n">x</span><span class="p">,</span> <span class="n">y</span> <span class="o">=</span> <span class="n">event</span><span class="p">[</span><span class="s2">&quot;mouse_down_position&quot;</span><span class="p">]</span>
    <span class="o">...</span>
</pre></div>
</div>
</div>
<div class="line-block">
<div class="line">在一个事件周期内希望重新绘制时，需要调用 <strong>event.set_redraw()</strong> 方法</div>
<div class="line">该方法不会立即绘制而是等待所有输入事件结束后调用 root._draw_event()</div>
<div class="line">需要取消事件时，调用 event.set_cancel() 方法, 这样c4d 其他界面控件就可以捕获到这个事件并作出反馈。</div>
</div>
<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.CHANNEL_MOUSELEFT">
<span class="sig-name descname"><span class="pre">CHANNEL_MOUSELEFT</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#ualib.core.BaseEvent.CHANNEL_MOUSELEFT" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.CHANNEL_MOUSEMIDDLE">
<span class="sig-name descname"><span class="pre">CHANNEL_MOUSEMIDDLE</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#ualib.core.BaseEvent.CHANNEL_MOUSEMIDDLE" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.CHANNEL_MOUSEMOVE">
<span class="sig-name descname"><span class="pre">CHANNEL_MOUSEMOVE</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">101</span></em><a class="headerlink" href="#ualib.core.BaseEvent.CHANNEL_MOUSEMOVE" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.CHANNEL_MOUSERIGHT">
<span class="sig-name descname"><span class="pre">CHANNEL_MOUSERIGHT</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#ualib.core.BaseEvent.CHANNEL_MOUSERIGHT" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.CHANNEL_MOUSEWHEEL">
<span class="sig-name descname"><span class="pre">CHANNEL_MOUSEWHEEL</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">100</span></em><a class="headerlink" href="#ualib.core.BaseEvent.CHANNEL_MOUSEWHEEL" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.DEVICE_KEYBOARD">
<span class="sig-name descname"><span class="pre">DEVICE_KEYBOARD</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1801812322</span></em><a class="headerlink" href="#ualib.core.BaseEvent.DEVICE_KEYBOARD" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.DEVICE_MOUSE">
<span class="sig-name descname"><span class="pre">DEVICE_MOUSE</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1836021107</span></em><a class="headerlink" href="#ualib.core.BaseEvent.DEVICE_MOUSE" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.EVENT_TYPE_DOWN">
<span class="sig-name descname"><span class="pre">EVENT_TYPE_DOWN</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#ualib.core.BaseEvent.EVENT_TYPE_DOWN" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.EVENT_TYPE_HOLD">
<span class="sig-name descname"><span class="pre">EVENT_TYPE_HOLD</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#ualib.core.BaseEvent.EVENT_TYPE_HOLD" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.EVENT_TYPE_NONE">
<span class="sig-name descname"><span class="pre">EVENT_TYPE_NONE</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#ualib.core.BaseEvent.EVENT_TYPE_NONE" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.EVENT_TYPE_TIMER">
<span class="sig-name descname"><span class="pre">EVENT_TYPE_TIMER</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">4</span></em><a class="headerlink" href="#ualib.core.BaseEvent.EVENT_TYPE_TIMER" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.EVENT_TYPE_UP">
<span class="sig-name descname"><span class="pre">EVENT_TYPE_UP</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#ualib.core.BaseEvent.EVENT_TYPE_UP" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.QUALIFIERS_ALT">
<span class="sig-name descname"><span class="pre">QUALIFIERS_ALT</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">4</span></em><a class="headerlink" href="#ualib.core.BaseEvent.QUALIFIERS_ALT" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.QUALIFIERS_CTRL">
<span class="sig-name descname"><span class="pre">QUALIFIERS_CTRL</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#ualib.core.BaseEvent.QUALIFIERS_CTRL" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.QUALIFIERS_NONE">
<span class="sig-name descname"><span class="pre">QUALIFIERS_NONE</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#ualib.core.BaseEvent.QUALIFIERS_NONE" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.QUALIFIERS_SHIFT">
<span class="sig-name descname"><span class="pre">QUALIFIERS_SHIFT</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#ualib.core.BaseEvent.QUALIFIERS_SHIFT" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.clone">
<span class="sig-name descname"><span class="pre">clone</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.clone" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.get_key_value">
<span class="sig-name descname"><span class="pre">get_key_value</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.get_key_value" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.get_mouse_pos">
<span class="sig-name descname"><span class="pre">get_mouse_pos</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.get_mouse_pos" title="Permalink to this definition"></a></dt>
<dd><p>获取当前事件中的鼠标位置，down hold up timer都可以返回</p>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>除了通过这个方法，也可以通过 event[key]的方式(如event[&quot;mouse_down_position&quot;])在不同事件中获取其他事件的鼠标位置。</p>
<table class="hlist"><tr><td><ul class="simple">
<li><p>mouse_event_position :列表[x,y] 对应事件按键点击时鼠标的位置。</p></li>
<li><p>mouse_down_position : 列表[x,y] 按键点击时鼠标的位置。</p></li>
<li><p>mouse_hold_position : 列表[x,y] 按键点击并拖动时鼠标的位置。</p></li>
<li><p>mouse_up_position : 列表[x,y] 按键松开时鼠标的位置。</p></li>
</ul>
</td></tr></table>
</div>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="k">def</span> <span class="nf">_event</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">event</span><span class="p">:</span> <span class="n">BaseEvent</span><span class="p">):</span>
    <span class="c1"># 等于 x, y = event[&quot;mouse_event_position&quot;]</span>
    <span class="n">x</span><span class="p">,</span> <span class="n">y</span> <span class="o">=</span> <span class="n">event</span><span class="o">.</span><span class="n">get_mouse_pos</span><span class="p">()</span>
    <span class="o">...</span>
</pre></div>
</div>
<div class="admonition seealso">
<p class="admonition-title">See also</p>
<p><span class="xref std std-doc">__getitem__</span> 中有所有可获取的 <strong>event</strong> 数据</p>
</div>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>list</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>[x,y] 鼠标相对画布的位置</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.get_wheel_value">
<span class="sig-name descname"><span class="pre">get_wheel_value</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.get_wheel_value" title="Permalink to this definition"></a></dt>
<dd><p>获取滚轮每次滚动的数值</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool
int: 每次滚轮滚动的量</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.init">
<span class="sig-name descname"><span class="pre">init</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.init" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.init_event_data">
<span class="sig-name descname"><span class="pre">init_event_data</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">msg</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.init_event_data" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_alt_pressed">
<span class="sig-name descname"><span class="pre">is_alt_pressed</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_alt_pressed" title="Permalink to this definition"></a></dt>
<dd><p>alt点击</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>alt点击时返回True</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_cancel">
<span class="sig-name descname"><span class="pre">is_cancel</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_cancel" title="Permalink to this definition"></a></dt>
<dd><p>事件是否取消</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>返回True 如果事件已取消</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_ctrl_pressed">
<span class="sig-name descname"><span class="pre">is_ctrl_pressed</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_ctrl_pressed" title="Permalink to this definition"></a></dt>
<dd><p>ctrl点击</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>ctrl点击时返回True</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_double_click">
<span class="sig-name descname"><span class="pre">is_double_click</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_double_click" title="Permalink to this definition"></a></dt>
<dd><p>是否是双击</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>双击时返回True</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_down_event">
<span class="sig-name descname"><span class="pre">is_down_event</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_down_event" title="Permalink to this definition"></a></dt>
<dd><p>按下事件</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>除了鼠标悬停外的所有事件都会返回True</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_handled">
<span class="sig-name descname"><span class="pre">is_handled</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_handled" title="Permalink to this definition"></a></dt>
<dd><p>事件是否已处理</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>返回True 如果事件已处理</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_hold_event">
<span class="sig-name descname"><span class="pre">is_hold_event</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_hold_event" title="Permalink to this definition"></a></dt>
<dd><p>拖拽事件</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>当发生拖拽时，除了鼠标悬停外的所有事件都会返回True</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_key_pressed">
<span class="sig-name descname"><span class="pre">is_key_pressed</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_key_pressed" title="Permalink to this definition"></a></dt>
<dd><p>是否是键盘输入事件</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>当键盘输入时返回True</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_mouse_left_pressed">
<span class="sig-name descname"><span class="pre">is_mouse_left_pressed</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_mouse_left_pressed" title="Permalink to this definition"></a></dt>
<dd><p>鼠标左键点击</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>左键点击时为True</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_mouse_middle_pressed">
<span class="sig-name descname"><span class="pre">is_mouse_middle_pressed</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_mouse_middle_pressed" title="Permalink to this definition"></a></dt>
<dd><p>滚轮点击（又称为中键）</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>中键点击时返回True</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_mouse_pressed">
<span class="sig-name descname"><span class="pre">is_mouse_pressed</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_mouse_pressed" title="Permalink to this definition"></a></dt>
<dd><p>输入事件为鼠标事件</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>鼠标事件返回True</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_mouse_right_pressed">
<span class="sig-name descname"><span class="pre">is_mouse_right_pressed</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_mouse_right_pressed" title="Permalink to this definition"></a></dt>
<dd><p>鼠标右键点击</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>右键点击时返回True</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_mouse_wheel_scrolled">
<span class="sig-name descname"><span class="pre">is_mouse_wheel_scrolled</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_mouse_wheel_scrolled" title="Permalink to this definition"></a></dt>
<dd><p>滚轮滚动</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>滚轮滚动时返回True</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_redraw">
<span class="sig-name descname"><span class="pre">is_redraw</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_redraw" title="Permalink to this definition"></a></dt>
<dd><p>绘制是否被调用</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>返回True 如果需要绘制</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_shift_pressed">
<span class="sig-name descname"><span class="pre">is_shift_pressed</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_shift_pressed" title="Permalink to this definition"></a></dt>
<dd><p>shift点击</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>shift点击时返回True</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_special_key_pressed">
<span class="sig-name descname"><span class="pre">is_special_key_pressed</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">key</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">61856</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_special_key_pressed" title="Permalink to this definition"></a></dt>
<dd><p>KEY_MLEFT
KEY_MRIGHT
KEY_MMIDDLE
KEY_MX1
KEY_MX2
KEY_SHIFT
KEY_CONTROL
KEY_ALT
KEY_CAPSLOCK
KEY_MODIFIERS
KEY_COMMAND
KEY_BACKSPACE
KEY_TAB
KEY_ENTER
KEY_ESC
KEY_SPACE
KEY_DELETE
KEY_UP
KEY_DOWN
KEY_LEFT
KEY_RIGHT
KEY_PGUP
KEY_PGDOWN
KEY_HOME
KEY_END
KEY_INSERT
KEY_F1
KEY_F2
KEY_F3
KEY_F4
KEY_F5
KEY_F6
KEY_F7
KEY_F8
KEY_F9
KEY_F10
KEY_F11
KEY_F12
KEY_F13
KEY_F14
KEY_F15
KEY_F16
KEY_F17
KEY_F18
KEY_F19
KEY_F20
KEY_F21
KEY_F22
KEY_F23
KEY_F24
KEY_F25
KEY_F26
KEY_F27
KEY_F28
KEY_F29
KEY_F30
KEY_F31
KEY_F32</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_timer_event">
<span class="sig-name descname"><span class="pre">is_timer_event</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_timer_event" title="Permalink to this definition"></a></dt>
<dd><p>计时器事件</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>主要是鼠标悬停事件时返回True</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.is_up_event">
<span class="sig-name descname"><span class="pre">is_up_event</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.is_up_event" title="Permalink to this definition"></a></dt>
<dd><p>松开事件</p>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>除了鼠标悬停外的所有事件都会返回True</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.set_cancel">
<span class="sig-name descname"><span class="pre">set_cancel</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.set_cancel" title="Permalink to this definition"></a></dt>
<dd><p>设置事件为取消，事件会继续向下传递但不会有任何效果
此方法可以用于取消特定事件占用 c4d 界面其他控件的事件输入，</p>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>设置时, 在 GeUserArea.InputEvent() 中返回 False
比如：滚轮事件如果不使用 set_cancel() 来取消， 则用户就无法通过滚轮来让 ScrollGroup 滚动</p>
</div>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.set_handled">
<span class="sig-name descname"><span class="pre">set_handled</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">handled_message</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.set_handled" title="Permalink to this definition"></a></dt>
<dd><p>设置事件为已处理，这里的处理只是个布尔值，实际上并不会发生任何事情
需要用户自己通过 is_handled() 来判定事件是否在传入前已经被其他对象处理过</p>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>已处理的事件在AreaNode中将不再向下传递</p>
</div>
<p>如果你想要覆写 _event 方法，可以如下使用：</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="k">def</span> <span class="nf">_event</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">event</span><span class="p">):</span>
    <span class="nb">super</span><span class="p">()</span><span class="o">.</span><span class="n">_event</span><span class="p">(</span><span class="n">event</span><span class="p">)</span>
    <span class="k">if</span> <span class="ow">not</span> <span class="n">event</span><span class="o">.</span><span class="n">is_handled</span><span class="p">:</span>
        <span class="c1"># 执行你想要执行的功能</span>
        <span class="k">pass</span>
</pre></div>
</div>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>handled_message</strong> (<em>any</em>) -- 可以向上层对象返回处理事件的对象, 默认为 None</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseEvent.set_redraw">
<span class="sig-name descname"><span class="pre">set_redraw</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseEvent.set_redraw" title="Permalink to this definition"></a></dt>
<dd><p>延迟调用绘制，在一个事件循环周期结束后调用 GeUserArea.Redraw() 方法</p>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">BaseGraphicsItem</span></span><a class="headerlink" href="#ualib.core.BaseGraphicsItem" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.core.AreaNode" title="ualib.core.AreaNode"><code class="xref py py-class docutils literal notranslate"><span class="pre">AreaNode</span></code></a></p>
<p>基础图形对象, 事件只有在区域内部发生才会向下传递, 绘制也可以限制在区域内部</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>moveable</strong> (<em>bool</em>) -- &lt;prop&gt; True 前对象可以被拖拽</p></li>
<li><p><strong>focus</strong> (<em>bool</em>) -- &lt;prop&gt; 当前对象被聚焦时返回 True</p></li>
<li><p><strong>selectable</strong> (<em>bool</em>) -- &lt;prop&gt; True 对象可被选择</p></li>
<li><p><strong>selected</strong> (<em>bool</em>) -- &lt;prop&gt; 当前对象被选择时返回 True</p></li>
<li><p><strong>color</strong> (<em>c4d.Vector</em>) -- &lt;prop&gt; 绘制时使用的默认颜色</p></li>
<li><p><strong>opacity</strong> (<em>float</em>) -- &lt;prop&gt; 绘制时使用的默认透明度 (0-1)</p></li>
</ul>
</dd>
</dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem.BFH_CENTER">
<span class="sig-name descname"><span class="pre">BFH_CENTER</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#ualib.core.BaseGraphicsItem.BFH_CENTER" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem.BFH_FIT">
<span class="sig-name descname"><span class="pre">BFH_FIT</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">24</span></em><a class="headerlink" href="#ualib.core.BaseGraphicsItem.BFH_FIT" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem.BFH_LEFT">
<span class="sig-name descname"><span class="pre">BFH_LEFT</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">8</span></em><a class="headerlink" href="#ualib.core.BaseGraphicsItem.BFH_LEFT" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem.BFH_RIGHT">
<span class="sig-name descname"><span class="pre">BFH_RIGHT</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">16</span></em><a class="headerlink" href="#ualib.core.BaseGraphicsItem.BFH_RIGHT" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem.BFH_SCALE">
<span class="sig-name descname"><span class="pre">BFH_SCALE</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">32</span></em><a class="headerlink" href="#ualib.core.BaseGraphicsItem.BFH_SCALE" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem.BFH_SCALEFIT">
<span class="sig-name descname"><span class="pre">BFH_SCALEFIT</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">56</span></em><a class="headerlink" href="#ualib.core.BaseGraphicsItem.BFH_SCALEFIT" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem.BFV_BOTTOM">
<span class="sig-name descname"><span class="pre">BFV_BOTTOM</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#ualib.core.BaseGraphicsItem.BFV_BOTTOM" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem.BFV_CENTER">
<span class="sig-name descname"><span class="pre">BFV_CENTER</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#ualib.core.BaseGraphicsItem.BFV_CENTER" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem.BFV_FIT">
<span class="sig-name descname"><span class="pre">BFV_FIT</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#ualib.core.BaseGraphicsItem.BFV_FIT" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem.BFV_SCALE">
<span class="sig-name descname"><span class="pre">BFV_SCALE</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">4</span></em><a class="headerlink" href="#ualib.core.BaseGraphicsItem.BFV_SCALE" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem.BFV_SCALEFIT">
<span class="sig-name descname"><span class="pre">BFV_SCALEFIT</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">7</span></em><a class="headerlink" href="#ualib.core.BaseGraphicsItem.BFV_SCALEFIT" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem.BFV_TOP">
<span class="sig-name descname"><span class="pre">BFV_TOP</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#ualib.core.BaseGraphicsItem.BFV_TOP" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem.DEFUALT_COLOR">
<span class="sig-name descname"><span class="pre">DEFUALT_COLOR</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">&lt;c4d.Vector</span> <span class="pre">object&gt;</span></em><a class="headerlink" href="#ualib.core.BaseGraphicsItem.DEFUALT_COLOR" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem._mouse_drag_process_event">
<span class="sig-name descname"><span class="pre">_mouse_drag_process_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseGraphicsItem._mouse_drag_process_event" title="Permalink to this definition"></a></dt>
<dd><p>覆写方法</p>
<dl class="field-list simple">
</dl>
<p>鼠标拖拽事件，通过 start_drag_event() 激活。</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>event</strong> (<a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><em>BaseEvent</em></a>) -- 基础事件</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem._mouse_drag_start_event">
<span class="sig-name descname"><span class="pre">_mouse_drag_start_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseGraphicsItem._mouse_drag_start_event" title="Permalink to this definition"></a></dt>
<dd><p>覆写方法</p>
<dl class="field-list simple">
</dl>
<p>鼠标拖拽事件，通过 start_drag_event() 激活。</p>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>只会在拖拽开始时调用一次。</p>
</div>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>event</strong> (<a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><em>BaseEvent</em></a>) -- 基础事件</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem._mouse_press_event">
<span class="sig-name descname"><span class="pre">_mouse_press_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseGraphicsItem._mouse_press_event" title="Permalink to this definition"></a></dt>
<dd><p>覆写方法</p>
<dl class="field-list simple">
</dl>
<p>鼠标点击事件
可以通过 event.get_mouse_pos() 方法获取当前事件中的鼠标位置
可以通过 event.is_mouse_left_pressed() 方法获取是否是左击
可以通过 event.is_mouse_right_pressed() 方法获取是否是右击</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>event</strong> (<a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><em>BaseEvent</em></a>) -- 基础事件</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BaseGraphicsItem.set_drag_mouse_follow">
<span class="sig-name descname"><span class="pre">set_drag_mouse_follow</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">value</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">0.35</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BaseGraphicsItem.set_drag_mouse_follow" title="Permalink to this definition"></a></dt>
<dd><p>拖拽时的对象跟随鼠标延迟，通常保持默认即可。</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>value</strong> (<em>float</em><em>, </em><em>optional</em>) -- 0 到 1 之间。设置为 1 时完全没有延迟。, defaults to 0.35</p>
</dd>
</dl>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.BitmapItem">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">BitmapItem</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">bmp=None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">position=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">size=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BitmapItem" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.core.BaseGraphicsItem" title="ualib.core.BaseGraphicsItem"><code class="xref py py-class docutils literal notranslate"><span class="pre">BaseGraphicsItem</span></code></a></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BitmapItem.FIT_TYPE_FIT">
<span class="sig-name descname"><span class="pre">FIT_TYPE_FIT</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#ualib.core.BitmapItem.FIT_TYPE_FIT" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BitmapItem.FIT_TYPE_FULL">
<span class="sig-name descname"><span class="pre">FIT_TYPE_FULL</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#ualib.core.BitmapItem.FIT_TYPE_FULL" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BitmapItem.FIT_TYPE_HEIGHT">
<span class="sig-name descname"><span class="pre">FIT_TYPE_HEIGHT</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#ualib.core.BitmapItem.FIT_TYPE_HEIGHT" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BitmapItem.FIT_TYPE_NONE">
<span class="sig-name descname"><span class="pre">FIT_TYPE_NONE</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#ualib.core.BitmapItem.FIT_TYPE_NONE" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BitmapItem.FIT_TYPE_WIDTH">
<span class="sig-name descname"><span class="pre">FIT_TYPE_WIDTH</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">4</span></em><a class="headerlink" href="#ualib.core.BitmapItem.FIT_TYPE_WIDTH" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BitmapItem._draw">
<span class="sig-name descname"><span class="pre">_draw</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">ua</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BitmapItem._draw" title="Permalink to this definition"></a></dt>
<dd><p>绘制覆写方法，在这里一般只需绘制当前对象本身</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>ua</strong> (<a class="reference internal" href="#ualib.core.CoreGeUserArea" title="ualib.core.CoreGeUserArea"><em>CoreGeUserArea</em></a>) -- core 模块中的 CoreGeUserArea 对象</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BitmapItem._update">
<span class="sig-name descname"><span class="pre">_update</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BitmapItem._update" title="Permalink to this definition"></a></dt>
<dd><p>刷新绘制数据</p>
<dl class="field-list simple">
</dl>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>_update 方法会在 _draw_event 中自动调用，当执行具体的数据刷新时可以利用 dirty flag 来判断刷新时机避免无效的反复刷新（可以极大的提升效率）</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="k">def</span> <span class="nf">_update</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
    <span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">dirty_flag</span><span class="o">.</span><span class="n">has_flag</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">DIRTYFLAGS_CHANGES</span><span class="p">):</span>
        <span class="c1"># 内部数据更新代码写这里</span>
    <span class="k">elif</span> <span class="bp">self</span><span class="o">.</span><span class="n">dirty_flag</span><span class="o">.</span><span class="n">has_flag</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">DIRTYFLAGS_MATRIX</span><span class="p">):</span>
        <span class="c1"># 位置变换数据更新代码写这里</span>
</pre></div>
</div>
</div>
<div class="admonition warning">
<p class="admonition-title">Warning</p>
<p>_update() 本质上是在DrawMsg() 函数中调用的, 所以注意避免直接调用 CoreGeUserArea 的 LayoutChanged() 方法 , 否则可能会因陷入死循环而导致的C4D崩溃</p>
</div>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BitmapItem.change_bmp">
<span class="sig-name descname"><span class="pre">change_bmp</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">bmp</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BitmapItem.change_bmp" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BitmapItem.change_fit_type">
<span class="sig-name descname"><span class="pre">change_fit_type</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">fit_type</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">0</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BitmapItem.change_fit_type" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BitmapItem.change_size">
<span class="sig-name descname"><span class="pre">change_size</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">size</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BitmapItem.change_size" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.BoxContainer">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">BoxContainer</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="pre">position=&lt;c4d.Vector</span> <span class="pre">object&gt;,</span> <span class="pre">size=&lt;c4d.Vector</span> <span class="pre">object&gt;,</span> <span class="pre">gap=10,</span> <span class="pre">border=[10,</span> <span class="pre">10,</span> <span class="pre">10,</span> <span class="pre">10]</span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BoxContainer" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.core.BaseGraphicsItem" title="ualib.core.BaseGraphicsItem"><code class="xref py py-class docutils literal notranslate"><span class="pre">BaseGraphicsItem</span></code></a></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BoxContainer.LINESTYLE_DASHED">
<span class="sig-name descname"><span class="pre">LINESTYLE_DASHED</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#ualib.core.BoxContainer.LINESTYLE_DASHED" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BoxContainer.LINESTYLE_DASHED_BIG">
<span class="sig-name descname"><span class="pre">LINESTYLE_DASHED_BIG</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">4</span></em><a class="headerlink" href="#ualib.core.BoxContainer.LINESTYLE_DASHED_BIG" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BoxContainer.LINESTYLE_DASHED_INV">
<span class="sig-name descname"><span class="pre">LINESTYLE_DASHED_INV</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#ualib.core.BoxContainer.LINESTYLE_DASHED_INV" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BoxContainer.LINESTYLE_DOTTED">
<span class="sig-name descname"><span class="pre">LINESTYLE_DOTTED</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#ualib.core.BoxContainer.LINESTYLE_DOTTED" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.BoxContainer.LINESTYLE_NORMAL">
<span class="sig-name descname"><span class="pre">LINESTYLE_NORMAL</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#ualib.core.BoxContainer.LINESTYLE_NORMAL" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BoxContainer._update">
<span class="sig-name descname"><span class="pre">_update</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BoxContainer._update" title="Permalink to this definition"></a></dt>
<dd><p>刷新绘制数据</p>
<dl class="field-list simple">
</dl>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>_update 方法会在 _draw_event 中自动调用，当执行具体的数据刷新时可以利用 dirty flag 来判断刷新时机避免无效的反复刷新（可以极大的提升效率）</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="k">def</span> <span class="nf">_update</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
    <span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">dirty_flag</span><span class="o">.</span><span class="n">has_flag</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">DIRTYFLAGS_CHANGES</span><span class="p">):</span>
        <span class="c1"># 内部数据更新代码写这里</span>
    <span class="k">elif</span> <span class="bp">self</span><span class="o">.</span><span class="n">dirty_flag</span><span class="o">.</span><span class="n">has_flag</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">DIRTYFLAGS_MATRIX</span><span class="p">):</span>
        <span class="c1"># 位置变换数据更新代码写这里</span>
</pre></div>
</div>
</div>
<div class="admonition warning">
<p class="admonition-title">Warning</p>
<p>_update() 本质上是在DrawMsg() 函数中调用的, 所以注意避免直接调用 CoreGeUserArea 的 LayoutChanged() 方法 , 否则可能会因陷入死循环而导致的C4D崩溃</p>
</div>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.BoxContainer.add_child">
<span class="sig-name descname"><span class="pre">add_child</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">item</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">align_flag=0</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">minsize=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.BoxContainer.add_child" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.ClipMapTextItem">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">ClipMapTextItem</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">text='Defualt'</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">font_size=72</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">position=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">size=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.ClipMapTextItem" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.core.BaseGraphicsItem" title="ualib.core.BaseGraphicsItem"><code class="xref py py-class docutils literal notranslate"><span class="pre">BaseGraphicsItem</span></code></a></p>
<p>支持缩放的Text对象</p>
<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.ClipMapTextItem._draw">
<span class="sig-name descname"><span class="pre">_draw</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">ua</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.ClipMapTextItem._draw" title="Permalink to this definition"></a></dt>
<dd><p>绘制覆写方法，在这里一般只需绘制当前对象本身</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>ua</strong> (<a class="reference internal" href="#ualib.core.CoreGeUserArea" title="ualib.core.CoreGeUserArea"><em>CoreGeUserArea</em></a>) -- core 模块中的 CoreGeUserArea 对象</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.ClipMapTextItem._update">
<span class="sig-name descname"><span class="pre">_update</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.ClipMapTextItem._update" title="Permalink to this definition"></a></dt>
<dd><p>刷新绘制数据</p>
<dl class="field-list simple">
</dl>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>_update 方法会在 _draw_event 中自动调用，当执行具体的数据刷新时可以利用 dirty flag 来判断刷新时机避免无效的反复刷新（可以极大的提升效率）</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="k">def</span> <span class="nf">_update</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
    <span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">dirty_flag</span><span class="o">.</span><span class="n">has_flag</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">DIRTYFLAGS_CHANGES</span><span class="p">):</span>
        <span class="c1"># 内部数据更新代码写这里</span>
    <span class="k">elif</span> <span class="bp">self</span><span class="o">.</span><span class="n">dirty_flag</span><span class="o">.</span><span class="n">has_flag</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">DIRTYFLAGS_MATRIX</span><span class="p">):</span>
        <span class="c1"># 位置变换数据更新代码写这里</span>
</pre></div>
</div>
</div>
<div class="admonition warning">
<p class="admonition-title">Warning</p>
<p>_update() 本质上是在DrawMsg() 函数中调用的, 所以注意避免直接调用 CoreGeUserArea 的 LayoutChanged() 方法 , 否则可能会因陷入死循环而导致的C4D崩溃</p>
</div>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.ClipMapTextItem.get_text_clipmap_size">
<span class="sig-name descname"><span class="pre">get_text_clipmap_size</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.ClipMapTextItem.get_text_clipmap_size" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.ClipMapTextItem.set_change">
<span class="sig-name descname"><span class="pre">set_change</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">text</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">font_size</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">color</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">color_text_bg</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.ClipMapTextItem.set_change" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.CoreGeUserArea">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">CoreGeUserArea</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">root</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.CoreGeUserArea" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">GeUserArea</span></code></p>
<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.CoreGeUserArea.DrawMsg">
<span class="sig-name descname"><span class="pre">DrawMsg</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">x1</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">y1</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">x2</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">y2</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">msg</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.CoreGeUserArea.DrawMsg" title="Permalink to this definition"></a></dt>
<dd><div class="line-block">
<div class="line">Called when Cinema 4D wants you to draw your userarea.</div>
<div class="line">Use the drawing functions to update your user area in the region specified by the rectangle from (x1,y1) to (x2,y2).</div>
</div>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>x1</strong> (<em>int</em>) -- The upper left x coordinate.</p></li>
<li><p><strong>y1</strong> (<em>int</em>) -- The upper left y coordinate.</p></li>
<li><p><strong>x2</strong> (<em>int</em>) -- The lower right x coordinate.</p></li>
<li><p><strong>y2</strong> (<em>int</em>) -- The lower right y coordinate.</p></li>
<li><p><strong>msg</strong> (<em>c4d.BaseContainer</em>) -- A mesage container.</p></li>
</ul>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.CoreGeUserArea.GetMinSize">
<span class="sig-name descname"><span class="pre">GetMinSize</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.CoreGeUserArea.GetMinSize" title="Permalink to this definition"></a></dt>
<dd><p>Override this function to specify a minimum size for the user area.</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="k">def</span> <span class="nf">GetMinSize</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
    <span class="c1">#do a calculation here</span>
    <span class="k">return</span> <span class="bp">self</span><span class="o">.</span><span class="n">width</span><span class="p">,</span> <span class="bp">self</span><span class="o">.</span><span class="n">height</span>
</pre></div>
</div>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>Tuple[int, int]</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>A tuple with two elements just like this.</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.CoreGeUserArea.Init">
<span class="sig-name descname"><span class="pre">Init</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.CoreGeUserArea.Init" title="Permalink to this definition"></a></dt>
<dd><div class="line-block">
<div class="line">Called once when the user area is initialized by the GUI, before the layout is calculated.</div>
<div class="line">Override this function if you need to initialize anything.</div>
</div>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>Return <strong>True</strong> if successful, or <strong>False</strong> to signalize an error.</p>
</div>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p><strong>True</strong> if successful, or <strong>False</strong> to signalize an error.</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.CoreGeUserArea.InitValues">
<span class="sig-name descname"><span class="pre">InitValues</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.CoreGeUserArea.InitValues" title="Permalink to this definition"></a></dt>
<dd><div class="line-block">
<div class="line">Called after the layout is calculated, before the user area is drawn.</div>
<div class="line">Override this function if you need to initialize anything.</div>
</div>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>Return <strong>True</strong> if successful, or <strong>False</strong> to signalize an error.</p>
</div>
<dl class="field-list simple">
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p><strong>True</strong> if successful, or <strong>False</strong> to signalize an error.</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.CoreGeUserArea.InputEvent">
<span class="sig-name descname"><span class="pre">InputEvent</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">msg</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.CoreGeUserArea.InputEvent" title="Permalink to this definition"></a></dt>
<dd><div class="line-block">
<div class="line">Called when an input event is received.</div>
<div class="line">The information about the input event is stored in the <em>msg</em> container.</div>
</div>
<div class="admonition seealso">
<p class="admonition-title">See also</p>
<p><span class="xref std std-doc">Input Events</span>.</p>
</div>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>msg</strong> (<em>c4d.BaseContainer</em>) -- The event container.</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>bool</p>
</dd>
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>True</strong> if the event was handled, otherwise <strong>False</strong>.</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.CoreGeUserArea.Message">
<span class="sig-name descname"><span class="pre">Message</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">msg</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">result</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.CoreGeUserArea.Message" title="Permalink to this definition"></a></dt>
<dd><p>Override this function to react to more messages than covered by the other functions. Normally this is not necessary.</p>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>If overridden, include a call to the base version of this function, <code class="xref py py-meth docutils literal notranslate"><span class="pre">GeUserArea.Message()</span></code>:</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="k">def</span> <span class="nf">Message</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">msg</span><span class="p">,</span> <span class="n">result</span><span class="p">):</span>
    <span class="k">if</span> <span class="n">msg</span><span class="o">.</span><span class="n">GetId</span><span class="p">():</span>
        <span class="c1">#Do something</span>
        <span class="k">return</span> <span class="kc">True</span>

    <span class="k">return</span> <span class="n">c4d</span><span class="o">.</span><span class="n">gui</span><span class="o">.</span><span class="n">GeUserArea</span><span class="o">.</span><span class="n">Message</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">msg</span><span class="p">,</span> <span class="n">result</span><span class="p">)</span>
</pre></div>
</div>
</div>
<div class="admonition seealso">
<p class="admonition-title">See also</p>
<p><span class="xref std std-doc">/consts/MSG_C4DATOM_PLUGINS</span> for information on the messages type, data and input/output.</p>
</div>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>msg</strong> (<em>c4d.BaseContainer</em>) -- The message container.</p></li>
<li><p><strong>result</strong> (<em>c4d.BaseContainer</em>) -- A container to store results in.</p></li>
</ul>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>int</p>
</dd>
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>The return value depends on the message.</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.CoreGeUserArea.Sized">
<span class="sig-name descname"><span class="pre">Sized</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">w</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">h</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.CoreGeUserArea.Sized" title="Permalink to this definition"></a></dt>
<dd><p>Called when the user area is resized.</p>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>Override if you need to update anything.</p>
</div>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>w</strong> (<em>int</em>) -- The new width in pixels.</p></li>
<li><p><strong>h</strong> (<em>int</em>) -- The new height in pixels.</p></li>
</ul>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.CoreGeUserArea.Timer">
<span class="sig-name descname"><span class="pre">Timer</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">msg</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.CoreGeUserArea.Timer" title="Permalink to this definition"></a></dt>
<dd><div class="line-block">
<div class="line">If you subscribe to timer events using <code class="xref py py-meth docutils literal notranslate"><span class="pre">SetTimer()</span></code> (x), this function is called every <em>x</em> th millisecond.</div>
<div class="line">The raw timer message is stored in <em>msg</em>.</div>
</div>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>msg</strong> (<em>c4d.BaseContainer</em>) -- The timer message container.</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.CoreGeUserArea.new_event">
<span class="sig-name descname"><span class="pre">new_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event_type</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">msg</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">data</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.CoreGeUserArea.new_event" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.CoreGeUserArea.set_clipping_region_with">
<span class="sig-name descname"><span class="pre">set_clipping_region_with</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">x1</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">y1</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">x2</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">y2</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.CoreGeUserArea.set_clipping_region_with" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.CoreGeUserArea.set_mouse_cursor">
<span class="sig-name descname"><span class="pre">set_mouse_cursor</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">cursor</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.CoreGeUserArea.set_mouse_cursor" title="Permalink to this definition"></a></dt>
<dd><div class="line-block">
<div class="line">这样用 set_mouse_cursor(&quot;MOUSE_HIDE&quot;)</div>
<div class="line">MOUSE_HIDE  #Hide cursor.</div>
<div class="line">MOUSE_SHOW  #Show cursor.</div>
<div class="line">MOUSE_NORMAL  #Normal cursor.</div>
<div class="line">MOUSE_BUSY  #Busy cursor.</div>
<div class="line">MOUSE_CROSS  #Cross cursor.</div>
<div class="line">MOUSE_QUESTION  #Question cursor</div>
<div class="line">MOUSE_ZOOM_IN  #Zoom in cursor.</div>
<div class="line">MOUSE_ZOOM_OUT  #Zoom out cursor.</div>
<div class="line">MOUSE_FORBIDDEN  #Forbidden cursor.</div>
<div class="line">MOUSE_DELETE  #Delete cursor.</div>
<div class="line">MOUSE_COPY  #Copy cursor.</div>
<div class="line">MOUSE_INSERTCOPY  #Insert copy cursor.</div>
<div class="line">MOUSE_INSERTCOPYDOWN  #Insert copy down cursor.</div>
<div class="line">MOUSE_MOVE  #Move cursor.</div>
<div class="line">MOUSE_INSERTMOVE  #Insert move cursor.</div>
<div class="line">MOUSE_INSERTMOVEDOWN  #Insert move cursor.</div>
<div class="line">MOUSE_ARROW_H  #Horizontal cursor.</div>
<div class="line">MOUSE_ARROW_V  #Vertical cursor.</div>
<div class="line">MOUSE_ARROW_HV  #Horizontal and vertical arrow cursor.</div>
<div class="line">MOUSE_POINT_HAND  #Point hand cursor.</div>
<div class="line">MOUSE_MOVE_HAND  #Move hand cursor.</div>
<div class="line">MOUSE_IBEAM  #I-beam cursor.</div>
<div class="line">MOUSE_SELECT_LIVE  #Live selection cursor.</div>
<div class="line">MOUSE_SELECT_FREE  #Free selection cursor.</div>
<div class="line">MOUSE_SELECT_RECT  #Rectangle selection cursor.</div>
<div class="line">MOUSE_SELECT_POLY  #Polygon selection cursor.</div>
<div class="line">MOUSE_SPLINETOOLS  #Spline tools cursor.</div>
<div class="line">MOUSE_EXTRUDE  #Extrude cursor.</div>
<div class="line">MOUSE_NORMALMOVE  #Normal move cursor.</div>
<div class="line">MOUSE_ADDPOINTS  #Add points cursor.</div>
<div class="line">MOUSE_ADDPOLYGONS  #Add polygons cursor.</div>
<div class="line">MOUSE_BRIDGE  #Bridge cursor.</div>
<div class="line">MOUSE_MIRROR  #Mirror cursor.</div>
<div class="line">MOUSE_PAINTMOVE  #Paint move cursor.</div>
<div class="line">MOUSE_PAINTSELECTRECT  #Paint select rectangle cursor.</div>
<div class="line">MOUSE_PAINTSELECTCIRCLE  #Paint select circle cursor.</div>
<div class="line">MOUSE_PAINTSELECTPOLY  #Paint select polygon cursor.</div>
<div class="line">MOUSE_PAINTSELECTFREE  #Paint select free cursor.</div>
<div class="line">MOUSE_PAINTMAGICWAND  #Paint magic wand cursor.</div>
<div class="line">MOUSE_PAINTCOLORRANGE  #Paint color range cursor.</div>
<div class="line">MOUSE_PAINTFILL  #Paint fill cursor.</div>
<div class="line">MOUSE_PAINTPICK  #Paint pick cursor.</div>
<div class="line">MOUSE_PAINTBRUSH  #Paint brush cursor.</div>
<div class="line">MOUSE_PAINTCLONE  #Paint clone cursor.</div>
<div class="line">MOUSE_PAINTTEXT  #Paint text cursor.</div>
<div class="line">MOUSE_PAINTCROP  #Paint crop cursor.</div>
<div class="line">MOUSE_PAINTLINE  #Paint line cursor.</div>
<div class="line">MOUSE_PAINTPOLYSHAPE  #Paint polygon shape cursor</div>
</div>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.HBoxContainer">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">HBoxContainer</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="pre">position=&lt;c4d.Vector</span> <span class="pre">object&gt;,</span> <span class="pre">size=&lt;c4d.Vector</span> <span class="pre">object&gt;,</span> <span class="pre">gap=10,</span> <span class="pre">border=[10,</span> <span class="pre">10,</span> <span class="pre">10,</span> <span class="pre">10]</span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.HBoxContainer" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.core.BoxContainer" title="ualib.core.BoxContainer"><code class="xref py py-class docutils literal notranslate"><span class="pre">BoxContainer</span></code></a></p>
</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.Node">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">Node</span></span><a class="headerlink" href="#ualib.core.Node" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.utils.BaseHierarchy" title="ualib.utils.BaseHierarchy"><code class="xref py py-class docutils literal notranslate"><span class="pre">BaseHierarchy</span></code></a></p>
<p>最基础的抽象对象
继承自 BaseHierarchy类 所以可以实现不同Node对象间的父子级关系</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>prop</strong> (<em>dict</em>) -- 用于管理Node对象所有的常规属性 (后续prop属性会用 &lt;prop&gt; 表示)</p></li>
<li><p><strong>dirty_flag</strong> (<a class="reference internal" href="#ualib.utils.SimpleFlag" title="ualib.utils.SimpleFlag"><em>SimpleFlag</em></a>) -- 用于内部刷新使用的标志位对象</p></li>
<li><p><strong>user_flag</strong> (<a class="reference internal" href="#ualib.utils.SimpleFlag" title="ualib.utils.SimpleFlag"><em>SimpleFlag</em></a>) -- 用户可以自由使用的标志位对象</p></li>
</ul>
</dd>
</dl>
<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.Node.DIRTYFLAGS_CHANGES">
<span class="sig-name descname"><span class="pre">DIRTYFLAGS_CHANGES</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'changes'</span></em><a class="headerlink" href="#ualib.core.Node.DIRTYFLAGS_CHANGES" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.Node.DIRTYFLAGS_MATRIX">
<span class="sig-name descname"><span class="pre">DIRTYFLAGS_MATRIX</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">'matrix'</span></em><a class="headerlink" href="#ualib.core.Node.DIRTYFLAGS_MATRIX" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node._draw">
<span class="sig-name descname"><span class="pre">_draw</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">ua</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node._draw" title="Permalink to this definition"></a></dt>
<dd><p>绘制覆写方法，在这里一般只需绘制当前对象本身</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>ua</strong> (<a class="reference internal" href="#ualib.core.CoreGeUserArea" title="ualib.core.CoreGeUserArea"><em>CoreGeUserArea</em></a>) -- core 模块中的 CoreGeUserArea 对象</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node._draw_child">
<span class="sig-name descname"><span class="pre">_draw_child</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">ua</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">parent_region</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">list</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node._draw_child" title="Permalink to this definition"></a></dt>
<dd><p>子对象绘制覆写方法，在这里一般绘制所有子对象，从后向前绘制，列表首位的子对象会显示在视图最上层</p>
<dl class="field-list simple">
</dl>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>insert_under方法会将子对象添加到 _children 列表的首位
insert_underlast 会添加到末尾
注意两种不同方式添加子对象绘制出来的前后顺序会不一样
其他添加方法查看 BaseHierarchy</p>
</div>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>ua</strong> (<a class="reference internal" href="#ualib.core.CoreGeUserArea" title="ualib.core.CoreGeUserArea"><em>CoreGeUserArea</em></a>) -- core 模块中的 CoreGeUserArea 对象</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node._draw_event">
<span class="sig-name descname"><span class="pre">_draw_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">ua</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">parent_region</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">list</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node._draw_event" title="Permalink to this definition"></a></dt>
<dd><p>绘制事件</p>
<dl class="field-list simple">
</dl>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>如果覆写该方法需要注意：内部刷新事件需要在绘制前调用并尽量遵循以下原则：</p>
<table class="hlist"><tr><td><ul class="simple">
<li><p>1.先调用 _update() 进行数据刷新</p></li>
<li><p>2.调用 _draw() 绘制当前对象</p></li>
<li><p>3.调用 _draw_child() 绘制子对象</p></li>
<li><p>4.调用 dirty_flag.clear_all_flags() 清理本次事件循环产生的 dirty flag</p></li>
<li><p>5.调用 user_flag.clear_all_flags() 清理本次事件循环产生的 user flag</p></li>
</ul>
</td></tr></table>
</div>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>ua</strong> (<a class="reference internal" href="#ualib.core.CoreGeUserArea" title="ualib.core.CoreGeUserArea"><em>CoreGeUserArea</em></a>) -- core 模块中的 CoreGeUserArea 对象</p></li>
<li><p><strong>parent_region</strong> (<em>list</em>) -- [x1,y1,x2,y2]</p></li>
</ul>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node._event">
<span class="sig-name descname"><span class="pre">_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node._event" title="Permalink to this definition"></a></dt>
<dd><p>事件处理,会将事件自动向下传递</p>
<dl class="field-list simple">
</dl>
<p>采用事件冒泡的规则，优先处理子对象的事件再处理父对象，当 event.is_handled() 为True 事件停止转递，
覆写方法时应该先调用 super()._event(event) 再根据 event.is_handled() 的状态执行相应代码。</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>event</strong> (<a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><em>BaseEvent</em></a>) -- 基础事件对象</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node._update">
<span class="sig-name descname"><span class="pre">_update</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node._update" title="Permalink to this definition"></a></dt>
<dd><p>刷新绘制数据</p>
<dl class="field-list simple">
</dl>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>_update 方法会在 _draw_event 中自动调用，当执行具体的数据刷新时可以利用 dirty flag 来判断刷新时机避免无效的反复刷新（可以极大的提升效率）</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="k">def</span> <span class="nf">_update</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
    <span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">dirty_flag</span><span class="o">.</span><span class="n">has_flag</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">DIRTYFLAGS_CHANGES</span><span class="p">):</span>
        <span class="c1"># 内部数据更新代码写这里</span>
    <span class="k">elif</span> <span class="bp">self</span><span class="o">.</span><span class="n">dirty_flag</span><span class="o">.</span><span class="n">has_flag</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">DIRTYFLAGS_MATRIX</span><span class="p">):</span>
        <span class="c1"># 位置变换数据更新代码写这里</span>
</pre></div>
</div>
</div>
<div class="admonition warning">
<p class="admonition-title">Warning</p>
<p>_update() 本质上是在DrawMsg() 函数中调用的, 所以注意避免直接调用 CoreGeUserArea 的 LayoutChanged() 方法 , 否则可能会因陷入死循环而导致的C4D崩溃</p>
</div>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node.change_prop">
<span class="sig-name descname"><span class="pre">change_prop</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">key</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">value</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node.change_prop" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.Node2D">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">Node2D</span></span><a class="headerlink" href="#ualib.core.Node2D" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.core.Node" title="ualib.core.Node"><code class="xref py py-class docutils literal notranslate"><span class="pre">Node</span></code></a>, <a class="reference internal" href="#ualib.utils.BaseFrame" title="ualib.utils.BaseFrame"><code class="xref py py-class docutils literal notranslate"><span class="pre">BaseFrame</span></code></a></p>
<p>最基础的2D对象, 所有对象应该基于这个类创建</p>
<p>除了继承 Node类, 最重要的是Node2D继承了 BaseFrame类， 可以设置位置大小等参数
也可以通过 get_global_position() 在嵌套的父子级关系中获取全局坐标，方便用来最终绘制</p>
<p>常用的输入事件覆写以下方法使用：</p>
<table class="hlist"><tr><td><ul class="simple">
<li><p><strong>_mouse_move_event</strong> 鼠标悬停</p></li>
<li><p><strong>_doubleclick_event</strong> 双击</p></li>
<li><p><strong>_mouse_press_event</strong> 鼠标点击</p></li>
<li><p><strong>_key_press_event</strong> 键盘点击</p></li>
<li><p><strong>_wheel_event</strong> 鼠标滚轮</p></li>
<li><p><strong>_mouse_drag_start_event</strong> 鼠标拖拽开始</p></li>
<li><p><strong>_mouse_drag_process_event</strong> 鼠标拖拽</p></li>
<li><p><strong>_mouse_drag_release_event</strong> 鼠标拖拽结束</p></li>
</ul>
</td></tr></table>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>global_frame_changed</strong> (<a class="reference internal" href="#ualib.utils.Signal" title="ualib.utils.Signal"><em>Signal</em></a>) -- 当对象的位置发送改变时发射信号，并将所有下级的 DIRTYFLAGS_MATRIX 设置为 True</p>
</dd>
</dl>
<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node2D._debug_draw_frame">
<span class="sig-name descname"><span class="pre">_debug_draw_frame</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">ua</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node2D._debug_draw_frame" title="Permalink to this definition"></a></dt>
<dd><dl class="field-list simple">
</dl>
<p>此方法用于 debug, 用户只需将 AUA.ua.draw_debug_frames 设为True 则所有 Node2D 都会绘制用于debug的红色虚线外轮廓</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node2D._doubleclick_event">
<span class="sig-name descname"><span class="pre">_doubleclick_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node2D._doubleclick_event" title="Permalink to this definition"></a></dt>
<dd><p>覆写方法</p>
<dl class="field-list simple">
</dl>
<p>鼠标双击事件
可以通过 event.is_mouse_left_pressed() 方法获取是否是左键双击</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>event</strong> (<a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><em>BaseEvent</em></a>) -- 基础事件</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node2D._key_press_event">
<span class="sig-name descname"><span class="pre">_key_press_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node2D._key_press_event" title="Permalink to this definition"></a></dt>
<dd><p>覆写方法</p>
<dl class="field-list simple">
</dl>
<p>键盘点击事件
可以通过 event.get_key_value() 方法获取当前输入的字符</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>event</strong> (<a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><em>BaseEvent</em></a>) -- 基础事件</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node2D._mouse_drag_process_event">
<span class="sig-name descname"><span class="pre">_mouse_drag_process_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node2D._mouse_drag_process_event" title="Permalink to this definition"></a></dt>
<dd><p>覆写方法</p>
<dl class="field-list simple">
</dl>
<p>鼠标拖拽事件，通过 start_drag_event() 激活。</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>event</strong> (<a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><em>BaseEvent</em></a>) -- 基础事件</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node2D._mouse_drag_release_event">
<span class="sig-name descname"><span class="pre">_mouse_drag_release_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node2D._mouse_drag_release_event" title="Permalink to this definition"></a></dt>
<dd><p>覆写方法</p>
<dl class="field-list simple">
</dl>
<p>鼠标拖拽事件，通过 start_drag_event() 激活。</p>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>只会在拖拽结束时调用一次。</p>
</div>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>event</strong> (<a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><em>BaseEvent</em></a>) -- 基础事件</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node2D._mouse_drag_start_event">
<span class="sig-name descname"><span class="pre">_mouse_drag_start_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node2D._mouse_drag_start_event" title="Permalink to this definition"></a></dt>
<dd><p>覆写方法</p>
<dl class="field-list simple">
</dl>
<p>鼠标拖拽事件，通过 start_drag_event() 激活。</p>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>只会在拖拽开始时调用一次。</p>
</div>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>event</strong> (<a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><em>BaseEvent</em></a>) -- 基础事件</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node2D._mouse_move_event">
<span class="sig-name descname"><span class="pre">_mouse_move_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node2D._mouse_move_event" title="Permalink to this definition"></a></dt>
<dd><p>覆写方法</p>
<dl class="field-list simple">
</dl>
<p>鼠标悬停移动事件
可以通过 event.get_mouse_pos() 方法获取当前事件中的鼠标位置</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>event</strong> (<a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><em>BaseEvent</em></a>) -- 基础事件</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node2D._mouse_press_event">
<span class="sig-name descname"><span class="pre">_mouse_press_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node2D._mouse_press_event" title="Permalink to this definition"></a></dt>
<dd><p>覆写方法</p>
<dl class="field-list simple">
</dl>
<p>鼠标点击事件
可以通过 event.get_mouse_pos() 方法获取当前事件中的鼠标位置
可以通过 event.is_mouse_left_pressed() 方法获取是否是左击
可以通过 event.is_mouse_right_pressed() 方法获取是否是右击</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>event</strong> (<a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><em>BaseEvent</em></a>) -- 基础事件</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node2D._on_global_frame_changed">
<span class="sig-name descname"><span class="pre">_on_global_frame_changed</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node2D._on_global_frame_changed" title="Permalink to this definition"></a></dt>
<dd><dl class="field-list simple">
</dl>
<p>当对象的全局位置发生改变时自动调用该方法，将自己以及所有的子对象（包括曾子孙）的 dirty_flag 设立 DIRTYFLAGS_MATRIX 标志位
用于在后续的刷新中使用</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node2D._wheel_event">
<span class="sig-name descname"><span class="pre">_wheel_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node2D._wheel_event" title="Permalink to this definition"></a></dt>
<dd><p>覆写方法</p>
<dl class="field-list simple">
</dl>
<p>鼠标滚轮事件
可以通过 event.get_wheel_value() 方法获取当前输入的滚动量</p>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>注意：此事件默认调用 event.set_cancel() （可以防止拦截 ScrollGroup 的滚轮事件）</p>
</div>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>event</strong> (<a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><em>BaseEvent</em></a>) -- 基础事件</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.Node2D.start_drag_event">
<span class="sig-name descname"><span class="pre">start_drag_event</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">event</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><span class="pre">BaseEvent</span></a></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.Node2D.start_drag_event" title="Permalink to this definition"></a></dt>
<dd><p>开始拖拽事件。在 _mouse_press_event 中调用该方法可以激活 _mouse_drag_start_event，_mouse_drag_process_event，_mouse_drag_release_event 事件</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="k">def</span> <span class="nf">_mouse_press_event</span><span class="p">(</span><span class="n">event</span><span class="p">):</span>
    <span class="nb">print</span><span class="p">(</span><span class="s2">&quot;press called&quot;</span><span class="p">)</span>

    <span class="c1"># 可以先在上方执行鼠标按压命令，再调用拖拽。</span>
    <span class="bp">self</span><span class="o">.</span><span class="n">start_drag_event</span><span class="p">(</span><span class="n">event</span><span class="p">)</span>

<span class="k">def</span> <span class="nf">_mouse_drag_start_event</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">event</span><span class="p">:</span> <span class="n">BaseEvent</span><span class="p">):</span>
    <span class="nb">print</span><span class="p">(</span><span class="s2">&quot;drag_start called&quot;</span><span class="p">)</span>

<span class="k">def</span> <span class="nf">_mouse_drag_process_event</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">event</span><span class="p">:</span> <span class="n">BaseEvent</span><span class="p">):</span>
    <span class="nb">print</span><span class="p">(</span><span class="s2">&quot;drag_process called&quot;</span><span class="p">)</span>

<span class="k">def</span> <span class="nf">_mouse_drag_release_event</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">event</span><span class="p">:</span> <span class="n">BaseEvent</span><span class="p">):</span>
    <span class="nb">print</span><span class="p">(</span><span class="s2">&quot;drag_release called&quot;</span><span class="p">)</span>

<span class="c1"># &gt;&gt;&gt; &quot;press called&quot;</span>
<span class="c1"># &gt;&gt;&gt; &quot;drag_start called&quot;</span>
<span class="c1"># &gt;&gt;&gt; &quot;drag_process called&quot;</span>
<span class="c1"># &gt;&gt;&gt; &quot;drag_release called&quot;</span>
</pre></div>
</div>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>event</strong> (<a class="reference internal" href="#ualib.core.BaseEvent" title="ualib.core.BaseEvent"><em>BaseEvent</em></a>) -- 基础事件</p>
</dd>
<dt class="field-even">Raises<span class="colon">:</span></dt>
<dd class="field-even"><p><strong>TypeError</strong> -- 此事件必须要在 _mouse_press_event 函数中调用</p>
</dd>
</dl>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.RectItem">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">RectItem</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">position=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">size=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">fill=False</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">line_width=1</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">line_style=0</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.RectItem" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.core.BaseGraphicsItem" title="ualib.core.BaseGraphicsItem"><code class="xref py py-class docutils literal notranslate"><span class="pre">BaseGraphicsItem</span></code></a></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.RectItem.LINESTYLE_DASHED">
<span class="sig-name descname"><span class="pre">LINESTYLE_DASHED</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#ualib.core.RectItem.LINESTYLE_DASHED" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.RectItem.LINESTYLE_DASHED_BIG">
<span class="sig-name descname"><span class="pre">LINESTYLE_DASHED_BIG</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">4</span></em><a class="headerlink" href="#ualib.core.RectItem.LINESTYLE_DASHED_BIG" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.RectItem.LINESTYLE_DASHED_INV">
<span class="sig-name descname"><span class="pre">LINESTYLE_DASHED_INV</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#ualib.core.RectItem.LINESTYLE_DASHED_INV" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.RectItem.LINESTYLE_DOTTED">
<span class="sig-name descname"><span class="pre">LINESTYLE_DOTTED</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#ualib.core.RectItem.LINESTYLE_DOTTED" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.RectItem.LINESTYLE_NORMAL">
<span class="sig-name descname"><span class="pre">LINESTYLE_NORMAL</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#ualib.core.RectItem.LINESTYLE_NORMAL" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.RectItem._draw">
<span class="sig-name descname"><span class="pre">_draw</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">ua</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.RectItem._draw" title="Permalink to this definition"></a></dt>
<dd><p>绘制覆写方法，在这里一般只需绘制当前对象本身</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>ua</strong> (<a class="reference internal" href="#ualib.core.CoreGeUserArea" title="ualib.core.CoreGeUserArea"><em>CoreGeUserArea</em></a>) -- core 模块中的 CoreGeUserArea 对象</p>
</dd>
</dl>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.RoundRectItem">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">RoundRectItem</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">position=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">size=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">radius=15</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">round_offset=0.43</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">fill=False</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">line_width=2</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">line_style=0</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.RoundRectItem" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.core.BaseBezierItem" title="ualib.core.BaseBezierItem"><code class="xref py py-class docutils literal notranslate"><span class="pre">BaseBezierItem</span></code></a></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.RoundRectItem.LINESTYLE_DASHED">
<span class="sig-name descname"><span class="pre">LINESTYLE_DASHED</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#ualib.core.RoundRectItem.LINESTYLE_DASHED" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.RoundRectItem.LINESTYLE_DASHED_BIG">
<span class="sig-name descname"><span class="pre">LINESTYLE_DASHED_BIG</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">4</span></em><a class="headerlink" href="#ualib.core.RoundRectItem.LINESTYLE_DASHED_BIG" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.RoundRectItem.LINESTYLE_DASHED_INV">
<span class="sig-name descname"><span class="pre">LINESTYLE_DASHED_INV</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#ualib.core.RoundRectItem.LINESTYLE_DASHED_INV" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.RoundRectItem.LINESTYLE_DOTTED">
<span class="sig-name descname"><span class="pre">LINESTYLE_DOTTED</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#ualib.core.RoundRectItem.LINESTYLE_DOTTED" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.RoundRectItem.LINESTYLE_NORMAL">
<span class="sig-name descname"><span class="pre">LINESTYLE_NORMAL</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#ualib.core.RoundRectItem.LINESTYLE_NORMAL" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.RoundRectItem._update">
<span class="sig-name descname"><span class="pre">_update</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.RoundRectItem._update" title="Permalink to this definition"></a></dt>
<dd><p>刷新绘制数据</p>
<dl class="field-list simple">
</dl>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>_update 方法会在 _draw_event 中自动调用，当执行具体的数据刷新时可以利用 dirty flag 来判断刷新时机避免无效的反复刷新（可以极大的提升效率）</p>
<div class="highlight-python notranslate"><div class="highlight"><pre><span></span><span class="k">def</span> <span class="nf">_update</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span>
    <span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">dirty_flag</span><span class="o">.</span><span class="n">has_flag</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">DIRTYFLAGS_CHANGES</span><span class="p">):</span>
        <span class="c1"># 内部数据更新代码写这里</span>
    <span class="k">elif</span> <span class="bp">self</span><span class="o">.</span><span class="n">dirty_flag</span><span class="o">.</span><span class="n">has_flag</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">DIRTYFLAGS_MATRIX</span><span class="p">):</span>
        <span class="c1"># 位置变换数据更新代码写这里</span>
</pre></div>
</div>
</div>
<div class="admonition warning">
<p class="admonition-title">Warning</p>
<p>_update() 本质上是在DrawMsg() 函数中调用的, 所以注意避免直接调用 CoreGeUserArea 的 LayoutChanged() 方法 , 否则可能会因陷入死循环而导致的C4D崩溃</p>
</div>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.RoundRectItem.change_size">
<span class="sig-name descname"><span class="pre">change_size</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">size</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.RoundRectItem.change_size" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.RoundRectItem.get_rect">
<span class="sig-name descname"><span class="pre">get_rect</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.RoundRectItem.get_rect" title="Permalink to this definition"></a></dt>
<dd><p>获取由bezier_object组成的倒角矩形</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.RoundRectItem.set_radius">
<span class="sig-name descname"><span class="pre">set_radius</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">radius</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.RoundRectItem.set_radius" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.RoundRectItem.set_seperate_radius">
<span class="sig-name descname"><span class="pre">set_seperate_radius</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">lt</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">rt</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">rb</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">lb</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.RoundRectItem.set_seperate_radius" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.SimpelTextItem">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">SimpelTextItem</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">text='Defualt'</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">position=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.SimpelTextItem" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.core.BaseGraphicsItem" title="ualib.core.BaseGraphicsItem"><code class="xref py py-class docutils literal notranslate"><span class="pre">BaseGraphicsItem</span></code></a></p>
<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.SimpelTextItem.COLOR_TRANS">
<span class="sig-name descname"><span class="pre">COLOR_TRANS</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">999</span></em><a class="headerlink" href="#ualib.core.SimpelTextItem.COLOR_TRANS" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.SimpelTextItem.FONT_BIG">
<span class="sig-name descname"><span class="pre">FONT_BIG</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">4</span></em><a class="headerlink" href="#ualib.core.SimpelTextItem.FONT_BIG" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.SimpelTextItem.FONT_BIG_BOLD">
<span class="sig-name descname"><span class="pre">FONT_BIG_BOLD</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">5</span></em><a class="headerlink" href="#ualib.core.SimpelTextItem.FONT_BIG_BOLD" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.SimpelTextItem.FONT_BOLD">
<span class="sig-name descname"><span class="pre">FONT_BOLD</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">2</span></em><a class="headerlink" href="#ualib.core.SimpelTextItem.FONT_BOLD" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.SimpelTextItem.FONT_DEFAULT">
<span class="sig-name descname"><span class="pre">FONT_DEFAULT</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">0</span></em><a class="headerlink" href="#ualib.core.SimpelTextItem.FONT_DEFAULT" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.SimpelTextItem.FONT_ITALIC">
<span class="sig-name descname"><span class="pre">FONT_ITALIC</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">6</span></em><a class="headerlink" href="#ualib.core.SimpelTextItem.FONT_ITALIC" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.SimpelTextItem.FONT_MONOSPACED">
<span class="sig-name descname"><span class="pre">FONT_MONOSPACED</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">3</span></em><a class="headerlink" href="#ualib.core.SimpelTextItem.FONT_MONOSPACED" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.core.SimpelTextItem.FONT_STANDARD">
<span class="sig-name descname"><span class="pre">FONT_STANDARD</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">1</span></em><a class="headerlink" href="#ualib.core.SimpelTextItem.FONT_STANDARD" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.core.SimpelTextItem._draw">
<span class="sig-name descname"><span class="pre">_draw</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">ua</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.SimpelTextItem._draw" title="Permalink to this definition"></a></dt>
<dd><p>绘制覆写方法，在这里一般只需绘制当前对象本身</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>ua</strong> (<a class="reference internal" href="#ualib.core.CoreGeUserArea" title="ualib.core.CoreGeUserArea"><em>CoreGeUserArea</em></a>) -- core 模块中的 CoreGeUserArea 对象</p>
</dd>
</dl>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.core.VBoxContainer">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.core.</span></span><span class="sig-name descname"><span class="pre">VBoxContainer</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="pre">position=&lt;c4d.Vector</span> <span class="pre">object&gt;,</span> <span class="pre">size=&lt;c4d.Vector</span> <span class="pre">object&gt;,</span> <span class="pre">gap=10,</span> <span class="pre">border=[10,</span> <span class="pre">10,</span> <span class="pre">10,</span> <span class="pre">10]</span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.core.VBoxContainer" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.core.BoxContainer" title="ualib.core.BoxContainer"><code class="xref py py-class docutils literal notranslate"><span class="pre">BoxContainer</span></code></a></p>
</dd></dl>

</section>
<section id="module-ualib.utils">
<span id="ualib-utils-module"></span><h2>ualib.utils module<a class="headerlink" href="#module-ualib.utils" title="Permalink to this heading"></a></h2>
<dl class="py class">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.utils.</span></span><span class="sig-name descname"><span class="pre">BaseFrame</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">position=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">size=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseFrame" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <a class="reference internal" href="#ualib.utils.BaseHierarchy" title="ualib.utils.BaseHierarchy"><code class="xref py py-class docutils literal notranslate"><span class="pre">BaseHierarchy</span></code></a></p>
<div class="line-block">
<div class="line">基础区域对象,可以通过位置和尺寸来返回全局bbox属性 即: x1, y1, x2, y2</div>
<div class="line">可以通过set_alignment()方法或者offset, 设置中心点位置(默认在左上角)</div>
<div class="line">除此之外支持一些常用判定方法:</div>
<div class="line-block">
<div class="line">1 (x,y)点是否在该区域</div>
<div class="line">2 是否与区域 [x1, y1, x2, y2] 相交</div>
<div class="line">3 获取与区域 [x1, y1, x2, y2] 相交的区域 [ox1, oy1, ox2, oy2]</div>
<div class="line">...</div>
</div>
</div>
<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.ALIGNMENT_CENTER">
<span class="sig-name descname"><span class="pre">ALIGNMENT_CENTER</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">&lt;c4d.Vector</span> <span class="pre">object&gt;</span></em><a class="headerlink" href="#ualib.utils.BaseFrame.ALIGNMENT_CENTER" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.ALIGNMENT_LEFT_BOTTOM">
<span class="sig-name descname"><span class="pre">ALIGNMENT_LEFT_BOTTOM</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">&lt;c4d.Vector</span> <span class="pre">object&gt;</span></em><a class="headerlink" href="#ualib.utils.BaseFrame.ALIGNMENT_LEFT_BOTTOM" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.ALIGNMENT_LEFT_MID">
<span class="sig-name descname"><span class="pre">ALIGNMENT_LEFT_MID</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">&lt;c4d.Vector</span> <span class="pre">object&gt;</span></em><a class="headerlink" href="#ualib.utils.BaseFrame.ALIGNMENT_LEFT_MID" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.ALIGNMENT_LEFT_TOP">
<span class="sig-name descname"><span class="pre">ALIGNMENT_LEFT_TOP</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">&lt;c4d.Vector</span> <span class="pre">object&gt;</span></em><a class="headerlink" href="#ualib.utils.BaseFrame.ALIGNMENT_LEFT_TOP" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.ALIGNMENT_MID_BOTTOM">
<span class="sig-name descname"><span class="pre">ALIGNMENT_MID_BOTTOM</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">&lt;c4d.Vector</span> <span class="pre">object&gt;</span></em><a class="headerlink" href="#ualib.utils.BaseFrame.ALIGNMENT_MID_BOTTOM" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.ALIGNMENT_MID_TOP">
<span class="sig-name descname"><span class="pre">ALIGNMENT_MID_TOP</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">&lt;c4d.Vector</span> <span class="pre">object&gt;</span></em><a class="headerlink" href="#ualib.utils.BaseFrame.ALIGNMENT_MID_TOP" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.ALIGNMENT_RIGHT_BOTTOM">
<span class="sig-name descname"><span class="pre">ALIGNMENT_RIGHT_BOTTOM</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">&lt;c4d.Vector</span> <span class="pre">object&gt;</span></em><a class="headerlink" href="#ualib.utils.BaseFrame.ALIGNMENT_RIGHT_BOTTOM" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.ALIGNMENT_RIGHT_MID">
<span class="sig-name descname"><span class="pre">ALIGNMENT_RIGHT_MID</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">&lt;c4d.Vector</span> <span class="pre">object&gt;</span></em><a class="headerlink" href="#ualib.utils.BaseFrame.ALIGNMENT_RIGHT_MID" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.ALIGNMENT_RIGHT_TOP">
<span class="sig-name descname"><span class="pre">ALIGNMENT_RIGHT_TOP</span></span><em class="property"><span class="w"> </span><span class="p"><span class="pre">=</span></span><span class="w"> </span><span class="pre">&lt;c4d.Vector</span> <span class="pre">object&gt;</span></em><a class="headerlink" href="#ualib.utils.BaseFrame.ALIGNMENT_RIGHT_TOP" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.get_box_offset">
<span class="sig-name descname"><span class="pre">get_box_offset</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">offset=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseFrame.get_box_offset" title="Permalink to this definition"></a></dt>
<dd><p>获取相对的偏移位置， 可以用于获取中心点等特殊位置</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.get_global_bbox">
<span class="sig-name descname"><span class="pre">get_global_bbox</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseFrame.get_global_bbox" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.get_global_position">
<span class="sig-name descname"><span class="pre">get_global_position</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseFrame.get_global_position" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.get_overlap_rect_with">
<span class="sig-name descname"><span class="pre">get_overlap_rect_with</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">x1</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">y1</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">x2</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">y2</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseFrame.get_overlap_rect_with" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.is_intersect_with">
<span class="sig-name descname"><span class="pre">is_intersect_with</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">x1</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">y1</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">x2</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">y2</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseFrame.is_intersect_with" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.is_point_inside">
<span class="sig-name descname"><span class="pre">is_point_inside</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">x</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">y</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseFrame.is_point_inside" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py property">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.offset">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">offset</span></span><a class="headerlink" href="#ualib.utils.BaseFrame.offset" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py property">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.position">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">position</span></span><a class="headerlink" href="#ualib.utils.BaseFrame.position" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.rect_overlap">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">rect_overlap</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">ax1</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">ay1</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">ax2</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">ay2</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">bx1</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">by1</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">bx2</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">by2</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseFrame.rect_overlap" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py property">
<dt class="sig sig-object py" id="ualib.utils.BaseFrame.size">
<em class="property"><span class="pre">property</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">size</span></span><a class="headerlink" href="#ualib.utils.BaseFrame.size" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.utils.</span></span><span class="sig-name descname"><span class="pre">BaseHierarchy</span></span><a class="headerlink" href="#ualib.utils.BaseHierarchy" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>一个用于管理父子级关系的基类。</p>
<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.get_children">
<span class="sig-name descname"><span class="pre">get_children</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.get_children" title="Permalink to this definition"></a></dt>
<dd><p>获取该节点的子节点列表。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.get_down">
<span class="sig-name descname"><span class="pre">get_down</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.get_down" title="Permalink to this definition"></a></dt>
<dd><p>获取第一个子节点。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.get_downlast">
<span class="sig-name descname"><span class="pre">get_downlast</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.get_downlast" title="Permalink to this definition"></a></dt>
<dd><p>获取最后一个子节点。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.get_next">
<span class="sig-name descname"><span class="pre">get_next</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.get_next" title="Permalink to this definition"></a></dt>
<dd><p>获取下一个兄弟节点。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.get_pred">
<span class="sig-name descname"><span class="pre">get_pred</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.get_pred" title="Permalink to this definition"></a></dt>
<dd><p>获取前一个兄弟节点。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.get_up">
<span class="sig-name descname"><span class="pre">get_up</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.get_up" title="Permalink to this definition"></a></dt>
<dd><p>获取父节点。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.insert_after">
<span class="sig-name descname"><span class="pre">insert_after</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">obj</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.insert_after" title="Permalink to this definition"></a></dt>
<dd><p>在指定节点之后插入该节点。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.insert_before">
<span class="sig-name descname"><span class="pre">insert_before</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">obj</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.insert_before" title="Permalink to this definition"></a></dt>
<dd><p>在指定节点之前插入该节点。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.insert_under">
<span class="sig-name descname"><span class="pre">insert_under</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">obj</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.insert_under" title="Permalink to this definition"></a></dt>
<dd><p>将该节点添加为指定节点的第一个子节点。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.insert_underlast">
<span class="sig-name descname"><span class="pre">insert_underlast</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">obj</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.insert_underlast" title="Permalink to this definition"></a></dt>
<dd><p>将该节点添加为指定节点的最后一个子节点。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.iter_all_children">
<span class="sig-name descname"><span class="pre">iter_all_children</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.iter_all_children" title="Permalink to this definition"></a></dt>
<dd><p>获取该节点的所有子孙节点的生成器。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.remove">
<span class="sig-name descname"><span class="pre">remove</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.remove" title="Permalink to this definition"></a></dt>
<dd><p>从父节点的子节点列表中移除该节点。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.remove_all_children">
<span class="sig-name descname"><span class="pre">remove_all_children</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.remove_all_children" title="Permalink to this definition"></a></dt>
<dd><p>移除该节点的所有子节点。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.set_children">
<span class="sig-name descname"><span class="pre">set_children</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">children</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.set_children" title="Permalink to this definition"></a></dt>
<dd><p>设置子节点列表。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.BaseHierarchy.set_parent">
<span class="sig-name descname"><span class="pre">set_parent</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">parent</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.BaseHierarchy.set_parent" title="Permalink to this definition"></a></dt>
<dd><p>设置父节点。</p>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.utils.Signal">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.utils.</span></span><span class="sig-name descname"><span class="pre">Signal</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="o"><span class="pre">*</span></span><span class="n"><span class="pre">args_types</span></span></em>, <em class="sig-param"><span class="o"><span class="pre">**</span></span><span class="n"><span class="pre">kwargs_types</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.Signal" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>用于模仿pyqt中的Signal类。</p>
<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.Signal.connect">
<span class="sig-name descname"><span class="pre">connect</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">slot</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">Callable</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.Signal.connect" title="Permalink to this definition"></a></dt>
<dd><p>将槽函数连接到信号上。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.Signal.disconnect">
<span class="sig-name descname"><span class="pre">disconnect</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">slot</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.Signal.disconnect" title="Permalink to this definition"></a></dt>
<dd><p>将槽函数从信号上断开连接。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.Signal.emit">
<span class="sig-name descname"><span class="pre">emit</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="o"><span class="pre">*</span></span><span class="n"><span class="pre">args</span></span></em>, <em class="sig-param"><span class="o"><span class="pre">**</span></span><span class="n"><span class="pre">kwargs</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.Signal.emit" title="Permalink to this definition"></a></dt>
<dd><p>发送信号，调用所有连接的槽函数。</p>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.utils.SimpleFlag">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.utils.</span></span><span class="sig-name descname"><span class="pre">SimpleFlag</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">flag_names</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">List</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></span><span class="w"> </span><span class="o"><span class="pre">=</span></span><span class="w"> </span><span class="default_value"><span class="pre">[]</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.SimpleFlag" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>标志位类，用于管理和操作多个二进制标志位。</p>
<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.utils.SimpleFlag.flags">
<span class="sig-name descname"><span class="pre">flags</span></span><a class="headerlink" href="#ualib.utils.SimpleFlag.flags" title="Permalink to this definition"></a></dt>
<dd><p>所有标志位的值。</p>
<dl class="field-list simple">
<dt class="field-odd">Type<span class="colon">:</span></dt>
<dd class="field-odd"><p>int</p>
</dd>
</dl>
</dd></dl>

<dl class="py attribute">
<dt class="sig sig-object py" id="ualib.utils.SimpleFlag.flag_names">
<span class="sig-name descname"><span class="pre">flag_names</span></span><a class="headerlink" href="#ualib.utils.SimpleFlag.flag_names" title="Permalink to this definition"></a></dt>
<dd><p>所有标志位的名称。</p>
<dl class="field-list simple">
<dt class="field-odd">Type<span class="colon">:</span></dt>
<dd class="field-odd"><p>List[str]</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SimpleFlag.clear_all_flags">
<span class="sig-name descname"><span class="pre">clear_all_flags</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#ualib.utils.SimpleFlag.clear_all_flags" title="Permalink to this definition"></a></dt>
<dd><p>清除所有标志位。</p>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SimpleFlag.clear_flag">
<span class="sig-name descname"><span class="pre">clear_flag</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">flag</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span><span class="w"> </span><span class="p"><span class="pre">|</span></span><span class="w"> </span><span class="pre">int</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#ualib.utils.SimpleFlag.clear_flag" title="Permalink to this definition"></a></dt>
<dd><p>清除指定的标志位。</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>flag</strong> -- 标志位的名称或位置。</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SimpleFlag.get_flag_by_position">
<span class="sig-name descname"><span class="pre">get_flag_by_position</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">position</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">int</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">str</span></span></span><a class="headerlink" href="#ualib.utils.SimpleFlag.get_flag_by_position" title="Permalink to this definition"></a></dt>
<dd><p>通过位置获取标志位的名称。</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>position</strong> -- 标志位的位置。</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>标志位的名称。</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>str</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SimpleFlag.get_flag_names">
<span class="sig-name descname"><span class="pre">get_flag_names</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">List</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#ualib.utils.SimpleFlag.get_flag_names" title="Permalink to this definition"></a></dt>
<dd><p>获取所有标志位的名称。</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>所有标志位的名称列表。</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>List[str]</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SimpleFlag.get_flag_positions">
<span class="sig-name descname"><span class="pre">get_flag_positions</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">List</span><span class="p"><span class="pre">[</span></span><span class="pre">int</span><span class="p"><span class="pre">]</span></span></span></span><a class="headerlink" href="#ualib.utils.SimpleFlag.get_flag_positions" title="Permalink to this definition"></a></dt>
<dd><p>获取所有标志位的位置。</p>
<dl class="field-list simple">
<dt class="field-odd">Returns<span class="colon">:</span></dt>
<dd class="field-odd"><p>所有标志位的位置列表。</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>List[int]</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SimpleFlag.has_flag">
<span class="sig-name descname"><span class="pre">has_flag</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">flag</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span><span class="w"> </span><span class="p"><span class="pre">|</span></span><span class="w"> </span><span class="pre">int</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">bool</span></span></span><a class="headerlink" href="#ualib.utils.SimpleFlag.has_flag" title="Permalink to this definition"></a></dt>
<dd><p>检查是否存在指定的标志位。</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>flag</strong> -- 标志位的名称或位置。</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>True表示存在该标志位，False表示不存在。</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>bool</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SimpleFlag.init_flag">
<span class="sig-name descname"><span class="pre">init_flag</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">flag_names</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">List</span><span class="p"><span class="pre">[</span></span><span class="pre">str</span><span class="p"><span class="pre">]</span></span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.SimpleFlag.init_flag" title="Permalink to this definition"></a></dt>
<dd></dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SimpleFlag.set_flag">
<span class="sig-name descname"><span class="pre">set_flag</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">flag</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span><span class="w"> </span><span class="p"><span class="pre">|</span></span><span class="w"> </span><span class="pre">int</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#ualib.utils.SimpleFlag.set_flag" title="Permalink to this definition"></a></dt>
<dd><p>设置指定的标志位。</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>flag</strong> -- 标志位的名称或位置。</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SimpleFlag.toggle_flag">
<span class="sig-name descname"><span class="pre">toggle_flag</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">flag</span></span><span class="p"><span class="pre">:</span></span><span class="w"> </span><span class="n"><span class="pre">str</span><span class="w"> </span><span class="p"><span class="pre">|</span></span><span class="w"> </span><span class="pre">int</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">None</span></span></span><a class="headerlink" href="#ualib.utils.SimpleFlag.toggle_flag" title="Permalink to this definition"></a></dt>
<dd><p>切换指定的标志位。</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>flag</strong> -- 标志位的名称或位置。</p>
</dd>
</dl>
</dd></dl>

</dd></dl>

<dl class="py class">
<dt class="sig sig-object py" id="ualib.utils.SingleBezierObject">
<em class="property"><span class="pre">class</span><span class="w"> </span></em><span class="sig-prename descclassname"><span class="pre">ualib.utils.</span></span><span class="sig-name descname"><span class="pre">SingleBezierObject</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">start=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">end=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">start_hand_offset=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">end_hand_offset=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.SingleBezierObject" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">object</span></code></p>
<p>贝塞尔曲线对象</p>
<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SingleBezierObject.attach_bezier">
<span class="sig-name descname"><span class="pre">attach_bezier</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">bezier_object</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">attach_type</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">'end'</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.SingleBezierObject.attach_bezier" title="Permalink to this definition"></a></dt>
<dd><p>连接上下游 bezier_object</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>bezier_object</strong> (<a class="reference internal" href="#ualib.utils.SingleBezierObject" title="ualib.utils.SingleBezierObject"><em>SingleBezierObject</em></a>) -- SingleBezierObject</p></li>
<li><p><strong>attach_type</strong> (<em>str</em><em>, </em><em>optional</em>) -- &quot;start&quot; 或者 &quot;end&quot;</p></li>
</ul>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SingleBezierObject.change">
<span class="sig-name descname"><span class="pre">change</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">part</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">value</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">update</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">True</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.SingleBezierObject.change" title="Permalink to this definition"></a></dt>
<dd><p>修改BezierObject的参数</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>part</strong> (<em>str</em>) -- &quot;start&quot;, &quot;end&quot;,&quot;start_hand_offset&quot;,&quot;end_hand_offset&quot;, 中的一个</p></li>
<li><p><strong>value</strong> (<em>Vector</em>) -- 位置数据</p></li>
<li><p><strong>update</strong> (<em>bool</em>) -- 当 update 为 True时才会更新 start_list 和 points_list 属性,
若连续修改同一对象的不同part可以最后一次修改时设置True, 可以提升效率</p></li>
</ul>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SingleBezierObject.get_all_points">
<em class="property"><span class="pre">static</span><span class="w"> </span></em><span class="sig-name descname"><span class="pre">get_all_points</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">bezier_object_list</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">offset=&lt;c4d.Vector</span> <span class="pre">object&gt;</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">innder_update=False</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.SingleBezierObject.get_all_points" title="Permalink to this definition"></a></dt>
<dd><p>将独立的bezier_objects作为一个对象获取全局点位</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>bezier_object_list</strong> (<em>list</em>) -- SingleBezierObject 对象组成的列表</p></li>
<li><p><strong>offset</strong> (<em>Vector</em><em>, </em><em>list</em>) -- 偏移量</p></li>
<li><p><strong>innder_update</strong> (<em>bool</em>) -- 完全刷新所有对象的点位 (若已经刷新过,设置为False可以提升效率)</p></li>
</ul>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>[start x, start y]
points_list (list) : [other points]</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>start_list (list)</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SingleBezierObject.get_part">
<span class="sig-name descname"><span class="pre">get_part</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">part</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.SingleBezierObject.get_part" title="Permalink to this definition"></a></dt>
<dd><p>获取BezierObject的参数</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>part</strong> (<em>str</em>) -- &quot;start&quot;, &quot;end&quot;,&quot;start_hand_offset&quot;,&quot;end_hand_offset&quot;, 中的一个</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>四个控制点中对应part的位置</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>part (Vector)</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SingleBezierObject.get_points">
<span class="sig-name descname"><span class="pre">get_points</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">update</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">False</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.SingleBezierObject.get_points" title="Permalink to this definition"></a></dt>
<dd><p>获取当前对象绘制贝塞尔曲线所需的所有点</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>update</strong> (<em>bool</em><em>, </em><em>optional</em>) -- 是否刷新,若无刷新必要设为False可以提升效率</p>
</dd>
<dt class="field-even">Returns<span class="colon">:</span></dt>
<dd class="field-even"><p>[start x, start y]
points_list (list) : [other points]</p>
</dd>
<dt class="field-odd">Return type<span class="colon">:</span></dt>
<dd class="field-odd"><p>start_list (list)</p>
</dd>
</dl>
</dd></dl>

<dl class="py method">
<dt class="sig sig-object py" id="ualib.utils.SingleBezierObject.update_list">
<span class="sig-name descname"><span class="pre">update_list</span></span><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.SingleBezierObject.update_list" title="Permalink to this definition"></a></dt>
<dd><p>更新当前对象绘制贝塞尔曲线所需的所有点</p>
</dd></dl>

</dd></dl>

<dl class="py function">
<dt class="sig sig-object py" id="ualib.utils.get_bitmap_from">
<span class="sig-prename descclassname"><span class="pre">ualib.utils.</span></span><span class="sig-name descname"><span class="pre">get_bitmap_from</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">source</span></span></em><span class="sig-paren">)</span> <span class="sig-return"><span class="sig-return-icon">&#x2192;</span> <span class="sig-return-typehint"><span class="pre">BaseBitmap</span></span></span><a class="headerlink" href="#ualib.utils.get_bitmap_from" title="Permalink to this definition"></a></dt>
<dd><p>通过输入图片路径或者c4d icon id来返回对应的 bitmap对象</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>source</strong> (<em>int</em><em> or </em><em>str</em>) -- 对应参数</p>
</dd>
<dt class="field-even">Return type<span class="colon">:</span></dt>
<dd class="field-even"><p>c4d.bitmaps.BaseBitmap</p>
</dd>
</dl>
</dd></dl>

<dl class="py function">
<dt class="sig sig-object py" id="ualib.utils.set_mouse_pointer">
<span class="sig-prename descclassname"><span class="pre">ualib.utils.</span></span><span class="sig-name descname"><span class="pre">set_mouse_pointer</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">name</span></span></em><span class="sig-paren">)</span><a class="headerlink" href="#ualib.utils.set_mouse_pointer" title="Permalink to this definition"></a></dt>
<dd><div class="line-block">
<div class="line">这样用 set_mouse_pointer(&quot;MOUSE_HIDE&quot;)</div>
<div class="line">MOUSE_HIDE  #Hide cursor.</div>
<div class="line">MOUSE_SHOW  #Show cursor.</div>
<div class="line">MOUSE_NORMAL  #Normal cursor.</div>
<div class="line">MOUSE_BUSY  #Busy cursor.</div>
<div class="line">MOUSE_CROSS  #Cross cursor.</div>
<div class="line">MOUSE_QUESTION  #Question cursor</div>
<div class="line">MOUSE_ZOOM_IN  #Zoom in cursor.</div>
<div class="line">MOUSE_ZOOM_OUT  #Zoom out cursor.</div>
<div class="line">MOUSE_FORBIDDEN  #Forbidden cursor.</div>
<div class="line">MOUSE_DELETE  #Delete cursor.</div>
<div class="line">MOUSE_COPY  #Copy cursor.</div>
<div class="line">MOUSE_INSERTCOPY  #Insert copy cursor.</div>
<div class="line">MOUSE_INSERTCOPYDOWN  #Insert copy down cursor.</div>
<div class="line">MOUSE_MOVE  #Move cursor.</div>
<div class="line">MOUSE_INSERTMOVE  #Insert move cursor.</div>
<div class="line">MOUSE_INSERTMOVEDOWN  #Insert move cursor.</div>
<div class="line">MOUSE_ARROW_H  #Horizontal cursor.</div>
<div class="line">MOUSE_ARROW_V  #Vertical cursor.</div>
<div class="line">MOUSE_ARROW_HV  #Horizontal and vertical arrow cursor.</div>
<div class="line">MOUSE_POINT_HAND  #Point hand cursor.</div>
<div class="line">MOUSE_MOVE_HAND  #Move hand cursor.</div>
<div class="line">MOUSE_IBEAM  #I-beam cursor.</div>
<div class="line">MOUSE_SELECT_LIVE  #Live selection cursor.</div>
<div class="line">MOUSE_SELECT_FREE  #Free selection cursor.</div>
<div class="line">MOUSE_SELECT_RECT  #Rectangle selection cursor.</div>
<div class="line">MOUSE_SELECT_POLY  #Polygon selection cursor.</div>
<div class="line">MOUSE_SPLINETOOLS  #Spline tools cursor.</div>
<div class="line">MOUSE_EXTRUDE  #Extrude cursor.</div>
<div class="line">MOUSE_NORMALMOVE  #Normal move cursor.</div>
<div class="line">MOUSE_ADDPOINTS  #Add points cursor.</div>
<div class="line">MOUSE_ADDPOLYGONS  #Add polygons cursor.</div>
<div class="line">MOUSE_BRIDGE  #Bridge cursor.</div>
<div class="line">MOUSE_MIRROR  #Mirror cursor.</div>
<div class="line">MOUSE_PAINTMOVE  #Paint move cursor.</div>
<div class="line">MOUSE_PAINTSELECTRECT  #Paint select rectangle cursor.</div>
<div class="line">MOUSE_PAINTSELECTCIRCLE  #Paint select circle cursor.</div>
<div class="line">MOUSE_PAINTSELECTPOLY  #Paint select polygon cursor.</div>
<div class="line">MOUSE_PAINTSELECTFREE  #Paint select free cursor.</div>
<div class="line">MOUSE_PAINTMAGICWAND  #Paint magic wand cursor.</div>
<div class="line">MOUSE_PAINTCOLORRANGE  #Paint color range cursor.</div>
<div class="line">MOUSE_PAINTFILL  #Paint fill cursor.</div>
<div class="line">MOUSE_PAINTPICK  #Paint pick cursor.</div>
<div class="line">MOUSE_PAINTBRUSH  #Paint brush cursor.</div>
<div class="line">MOUSE_PAINTCLONE  #Paint clone cursor.</div>
<div class="line">MOUSE_PAINTTEXT  #Paint text cursor.</div>
<div class="line">MOUSE_PAINTCROP  #Paint crop cursor.</div>
<div class="line">MOUSE_PAINTLINE  #Paint line cursor.</div>
<div class="line">MOUSE_PAINTPOLYSHAPE  #Paint polygon shape cursor</div>
</div>
</dd></dl>

</section>
<section id="module-ualib">
<span id="module-contents"></span><h2>Module contents<a class="headerlink" href="#module-ualib" title="Permalink to this heading"></a></h2>
<p>author: jackadux
version: 1.0.0</p>
</section>
</section>


           </div>
          </div>
          <footer>

  <hr/>

  <div role="contentinfo">
    <p>&#169; Copyright 2023, JACKADUX.</p>
  </div>

  Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
    <a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
    provided by <a href="https://readthedocs.org">Read the Docs</a>.
   

</footer>
        </div>
      </div>
    </section>
  </div>
  <script>
      jQuery(function () {
          SphinxRtdTheme.Navigation.enable(true);
      });
  </script> 

</body>
</html>